Skip to content

Xtensa: set ISD::TRAP to Legal when HasDebug#123

Open
MabezDev wants to merge 1 commit intoespressif:release/esp_21.xfrom
MabezDev:xtensa-trap-legal
Open

Xtensa: set ISD::TRAP to Legal when HasDebug#123
MabezDev wants to merge 1 commit intoespressif:release/esp_21.xfrom
MabezDev:xtensa-trap-legal

Conversation

@MabezDev
Copy link

@MabezDev MabezDev commented Mar 12, 2026

  • Set ISD::TRAP to Legal (guarded by hasDebug()) in XtensaISelLowering.cpp
  • Without this, ISD::TRAP defaults to Expand, which lowers to call abort() during DAG legalization — before ISel can match Pat<(trap), (BREAK 1, 15)>
  • This caused undefined reference to 'abort' linker errors in no_std Xtensa targets

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.

1 participant