[all-commits] [llvm/llvm-project] 1c1128: [clang][driver] Do not emit default '-Tdata' for A...
Ben Shi via All-commits
all-commits at lists.llvm.org
Tue Feb 28 23:55:59 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 1c112897b20274852a9280d20cebd5c9f3619a7a
https://github.com/llvm/llvm-project/commit/1c112897b20274852a9280d20cebd5c9f3619a7a
Author: Ben Shi <powerman1st at 163.com>
Date: 2023-03-01 (Wed, 01 Mar 2023)
Changed paths:
M clang/lib/Driver/ToolChains/AVR.cpp
M clang/test/Driver/avr-ld.c
Log Message:
-----------
[clang][driver] Do not emit default '-Tdata' for AVR devices
Different AVR devices have different data regions. Current clang
driver emits a default '-Tdata' option to the linker. This way
works fine if there is no user specified linker script, but it
will cause conflicts if there is one.
A better solution for setting the default data region to GNU ld
is defining symbol __DATA_REGION_ORIGIN__, which is expected by
GNU ld's default AVR linker script.
Fixes https://github.com/llvm/llvm-project/issues/60362
Reviewed By: MaskRay
Differential Revision: https://reviews.llvm.org/D144533
More information about the All-commits
mailing list