aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/arch/x86_64/Lower.zig3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/arch/x86_64/Lower.zig b/src/arch/x86_64/Lower.zig
index 72c3b2af6e..7115c34eff 100644
--- a/src/arch/x86_64/Lower.zig
+++ b/src/arch/x86_64/Lower.zig
@@ -414,6 +414,7 @@ fn generic(lower: *Lower, inst: Mir.Inst) Error!void {
=> ._,
.linker_reloc => {
if (lower.bin_file.options.pic) {
+ assert(inst.data.rx.fixes == ._);
const reg = inst.data.rx.r1;
const extra = lower.mir.extraData(Mir.Reloc, inst.data.rx.payload).data;
_ = lower.reloc(.{ .linker_reloc = extra });
@@ -435,6 +436,7 @@ fn generic(lower: *Lower, inst: Mir.Inst) Error!void {
});
},
.lea => {
+ assert(inst.data.rx.fixes == ._);
const reg = inst.data.rx.r1;
const extra = lower.mir.extraData(Mir.Reloc, inst.data.rx.payload).data;
try lower.emit(.none, .mov, &.{
@@ -443,6 +445,7 @@ fn generic(lower: *Lower, inst: Mir.Inst) Error!void {
});
},
.mov => {
+ assert(inst.data.rx.fixes == ._);
const reg = inst.data.rx.r1;
const extra = lower.mir.extraData(Mir.Reloc, inst.data.rx.payload).data;
_ = lower.reloc(.{ .linker_reloc = extra });