Page MenuHomePhabricator

[NFC] Use higher level constructs to check for whitespace/newlines in the lexer
ClosedPublic

Authored by serge-sans-paille on Mar 15 2021, 10:23 AM.

Details

Summary

It turns out that according to valgrind and perf, it's also slightly faster.

Diff Detail

Event Timeline

serge-sans-paille requested review of this revision.Mar 15 2021, 10:23 AM
serge-sans-paille created this revision.
lattner accepted this revision.Mar 15 2021, 10:24 AM
This revision is now accepted and ready to land.Mar 15 2021, 10:24 AM

Concerning the performance aspect, when counting the number of instructions needed to compile the sqlite amalgametion, using

valgrind --tool=callgrind ./bin/clang  -c sqlite3.c -o/dev/null -w

I get 5,872,876,067 instructions after the patch, and 5,879,411,049 before.

This revision was landed with ongoing or failed builds.Mar 15 2021, 10:27 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptMar 15 2021, 10:27 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript