Skip to content

Rework assembler selection#140

Draft
MisterDA wants to merge 7 commits intotrunkfrom
rework-assembler-selection
Draft

Rework assembler selection#140
MisterDA wants to merge 7 commits intotrunkfrom
rework-assembler-selection

Conversation

@MisterDA
Copy link
Owner

@MisterDA MisterDA commented Jun 8, 2025

No description provided.

@MisterDA MisterDA force-pushed the rework-assembler-selection branch from b3a74ec to bc561fb Compare June 8, 2025 10:57
@MisterDA MisterDA force-pushed the rework-assembler-selection branch 2 times, most recently from 8d3ad33 to 7302e8b Compare June 25, 2025 09:46
MisterDA and others added 7 commits June 25, 2025 11:51
- Use Autoconf macros to discover the correct target prefix for
  `as`. Results are cached.
- Call `as` directly, bypassing the C compiler driver, on all
  platforms that expose `as`.
- Allow using `llvm-ml`/`llvm-ml64` when building with clang-cl. Note
  that LLVM 21 is required to assemble the current amd64nt.asm file.
- Remove the ASPP variable by imitating GNU Make implicit rules. Add
  support for ASFLAGS.

      # default
      COMPILE.S = $(CC) $(ASFLAGS) $(CPPFLAGS) -c
      COMPILE.s = $(AS) $(ASFLAGS)
      # default
      PREPROCESS.S = $(CPP) $(CPPFLAGS)

      %.o: %.s
      #  recipe to execute (built-in):
              $(COMPILE.s) -o $@ $<
      %.o: %.S
      #  recipe to execute (built-in):
              $(COMPILE.S) -o $@ $<
      %.s: %.S
      #  recipe to execute (built-in):
              $(PREPROCESS.S) $< > $@
Indication as to whether ocamlopt assembles files via the C compiler or
by calling the assembler directly.

Co-authored-by: Antonin Décimo <antonin@tarides.com>
mingw-w64 is based on GCC, so supports -fdebug-prefix-map, but the test
for it is skipped in configure. The test is no longer skipped (which
means that Config.c_has_debug_prefix_map returns true) but the flag is
still explicitly not used by the compilers (as before).
@MisterDA MisterDA force-pushed the rework-assembler-selection branch from 4b8897e to 1abc36d Compare June 25, 2025 09:51
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.

2 participants