This is an archive of the discontinued LLVM Phabricator instance.

[libc][NFC] Simplify LibcTest and trim down string allocations
ClosedPublic

Authored by gchatelet on Jun 9 2023, 12:53 AM.

Details

Summary

This is a bit of cleanup before working on logging via stream operator (i.e., EXPECT_XXX() << ...).

Diff Detail

Event Timeline

gchatelet created this revision.Jun 9 2023, 12:53 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJun 9 2023, 12:53 AM
gchatelet requested review of this revision.Jun 9 2023, 12:53 AM
sivachandra accepted this revision.Jun 9 2023, 1:15 AM

LGTM but one comment since you are here anyway.

libc/test/UnitTest/FPMatcher.h
22–23

Instead of this, I think we can get rid of the fputil namespace which is mostly a legacy remnant.

This revision is now accepted and ready to land.Jun 9 2023, 1:15 AM
gchatelet marked an inline comment as done.Jun 9 2023, 1:42 AM
gchatelet added inline comments.
libc/test/UnitTest/FPMatcher.h
22–23

Instead of this, I think we can get rid of the fputil namespace which is mostly a legacy remnant.

AFAICT this means removing the fputil namespace everywhere correct? If so I will probably do this in a separate patch as it's quite big.

sivachandra added inline comments.Jun 9 2023, 1:44 AM
libc/test/UnitTest/FPMatcher.h
22–23

I meant only in the test related components. You can do it separately.

gchatelet marked 2 inline comments as done.Jun 9 2023, 2:02 AM
gchatelet added inline comments.
libc/test/UnitTest/FPMatcher.h
22–23

👍

gchatelet updated this revision to Diff 529860.Jun 9 2023, 2:05 AM
gchatelet marked an inline comment as done.
  • Forgot namespaces in macro
gchatelet updated this revision to Diff 529863.Jun 9 2023, 2:11 AM
  • Also remove fputil intermediate namespace
gchatelet updated this revision to Diff 529868.Jun 9 2023, 2:27 AM
  • Fix formatting