*from Shakespeare’s “Macbeth”, Act IV, Scene I.
From Online Etymology Dictionary:
c. 1200, extended form of earlier wick “bad, wicked, false” (12c.), which apparently is an adjectival use of Old English wicca “wizard” (see witch). Formed as if a past participle, but there is no corresponding verb. For evolution, compare wretched from wretch. Slang ironic sense of “wonderful” first attested 1920, in F. Scott Fitzgerald. As an adverb from early 15c. Related: Wickedly.
c. 1200, wrecched, an irregular formation from wrecche “wretch” (see wretch). Also see wicked. Related: Wretchedly; wretchedness.”