Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add comment on why data is first
  • Loading branch information
brandtbucher committed May 1, 2024
commit 9ec64ac8f7db4d554a6fac97965e1e8dcc2341f2
1 change: 1 addition & 0 deletions Tools/jit/_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ def _dump_stencil(opname: str, group: _stencils.StencilGroup) -> typing.Iterator
row = " ".join(f"{byte:#04x}," for byte in stencil.body[i : i + 8])
yield f" {row}"
yield " };"
# Data is written first (so relaxations in the code work properly):
for part, stencil in [("data", group.data), ("code", group.code)]:
if stencil.body:
yield f" memcpy({part}, {part}_body, sizeof({part}_body));"
Expand Down