Skip to content

LATX, fix: Ignore segment bases in LEA - #429

Merged
LaurenIsACoder merged 1 commit into
lat-opensource:masterfrom
ganjue66da:tmp1
Aug 31, 2026
Merged

LATX, fix: Ignore segment bases in LEA#429
LaurenIsACoder merged 1 commit into
lat-opensource:masterfrom
ganjue66da:tmp1

Conversation

@ganjue66da

Copy link
Copy Markdown
Contributor

LEA computes an effective offset and must not apply FS or GS segment bases. The shared memory-address conversion path added the segment base and corrupted IDTest's embedded resource copy.
Copy the operand and clear its segment before lowering the address.

Summary / 变更说明

Validation / 验证

Checklist / 检查项

  • I have read CONTRIBUTING.md. / 我已阅读 CONTRIBUTING.md
  • Every commit contains a DCO sign-off (git commit -s). /
    每个提交都包含 DCO 签署(git commit -s)。
  • I have included relevant build or test results, or explained why they
    are not applicable. /
    我已提供相关构建或测试结果,或说明了不适用的原因。

LEA computes an effective offset and must not apply FS or GS segment
bases. The shared memory-address conversion path added the segment base
and corrupted IDTest's embedded resource copy.
Copy the operand and clear its segment before lowering the address.

Signed-off-by: Wenqiang Wei <weiwenqiang@mail.ustc.edu.cn>

@xiezyang xiezyang left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM。该修改符合 LEA 忽略 FS/GS 段基址的语义,保留了通用寄存器地址计算和地址位宽处理,同时避免了错误加入段基址。

@LaurenIsACoder
LaurenIsACoder merged commit 0ce47fc into lat-opensource:master Aug 31, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants