This is an archive of the discontinued LLVM Phabricator instance.

[clang][AVR] Improve avr-ld command line options
ClosedPublic

Authored by benshi001 on Dec 19 2020, 2:16 AM.

Diff Detail

Event Timeline

benshi001 created this revision.Dec 19 2020, 2:16 AM
benshi001 requested review of this revision.Dec 19 2020, 2:16 AM
Herald added a project: Restricted Project. · View Herald TranscriptDec 19 2020, 2:16 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript
dylanmckay accepted this revision.Jan 23 2021, 1:19 AM

Great patch!

This revision is now accepted and ready to land.Jan 23 2021, 1:19 AM
MaskRay requested changes to this revision.Jan 23 2021, 10:09 AM
MaskRay added a subscriber: MaskRay.
MaskRay added inline comments.
clang/lib/Driver/ToolChains/AVR.cpp
36–37

This may cause -Wmissing-field-initializers, please fix

clang/test/Driver/avr-ld.c
2

You need --sysroot and a mock ld file in the tree.

See lto.c

This revision now requires changes to proceed.Jan 23 2021, 10:09 AM
benshi001 updated this revision to Diff 318821.Jan 24 2021, 3:16 AM
benshi001 marked 2 inline comments as done.

If you remove your system GCC avr, does the test still work? This is the criteria whether the patch is acceptable.

clang/test/Driver/avr-ld.c
46

You can entirely delete the code.

benshi001 updated this revision to Diff 318881.Jan 24 2021, 5:33 PM
benshi001 marked an inline comment as done.

If you remove your system GCC avr, does the test still work? This is the criteria whether the patch is acceptable.

Yes. The "make check-clang-driver" still passes without gcc-avr installation.

MaskRay accepted this revision.Jan 24 2021, 5:44 PM

LGTM.

This revision is now accepted and ready to land.Jan 24 2021, 5:44 PM
benshi001 closed this revision.Jan 24 2021, 8:04 PM
benshi001 reopened this revision.Jan 25 2021, 12:39 AM

It still cases many build failures, due to not enough test.

I will redo it with a full test.

This revision is now accepted and ready to land.Jan 25 2021, 12:39 AM
This revision was automatically updated to reflect the committed changes.