summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2008-08-24 18:09:04 -0700
committerH. Peter Anvin <hpa@zytor.com>2008-08-24 18:09:04 -0700
commit19f15a50f611bada1fc2445e4453283fa5acc47d (patch)
tree879a38c3434d9c0a6b67be97248e28a04d1f5d71
parent83b2e4f82c78c2464e76dfd09a30f8286830c45e (diff)
downloadnasm-19f15a50f611bada1fc2445e4453283fa5acc47d.tar.gz
BR 2067837: remove double add of VEX instruction length
We added the length of VEX prefixes twice in calcsize(); this resulted in the wrong symbol addresses when compiling without the optimizer. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
-rw-r--r--assemble.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/assemble.c b/assemble.c
index 73b5a3f1..9345fd8a 100644
--- a/assemble.c
+++ b/assemble.c
@@ -975,14 +975,12 @@ static int64_t calcsize(int32_t segment, int64_t offset, int bits,
case 0261:
case 0262:
case 0263:
- length += 2;
ins->rex |= REX_V;
ins->drexdst = regval(opx);
ins->vex_m = *codes++;
ins->vex_wlp = *codes++;
break;
case 0270:
- length += 2;
ins->rex |= REX_V;
ins->drexdst = 0;
ins->vex_m = *codes++;