[ADT] Micro-optimize the Triple constructor by doing a single split and
authorChandler Carruth <chandlerc@gmail.com>
Thu, 10 Sep 2015 07:51:43 +0000 (07:51 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Thu, 10 Sep 2015 07:51:43 +0000 (07:51 +0000)
commitaa69dede3582f0de67bb1aa08088fe549d32bff0
treeba9c64d06071fa2a70e4c199fe7aceb0f377db7b
parentf41971f6e7f9e5ba0c590c7e35e2c1af0cd38c69
[ADT] Micro-optimize the Triple constructor by doing a single split and
re-using the resulting components rather than repeatedly splitting and
re-splitting to compute each component as part of the initializer list.

This is more work on PR23676. Sadly, it doesn't help much. It removes
the constructor from my profile, but doesn't make a sufficient dent in
the total time. But it should play together nicely with subsequent
changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@247250 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Support/Triple.cpp