Make the copy member of StringRef/ArrayRef generic wrt allocators.
authorBenjamin Kramer <benny.kra@googlemail.com>
Fri, 18 Apr 2014 16:36:15 +0000 (16:36 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Fri, 18 Apr 2014 16:36:15 +0000 (16:36 +0000)
commite677b8dab13649541633bd120c5264fd91154549
tree9296eb8522908204c15ebb1b63016f4399b39ee2
parent675bf27ab70d6ea6dd3721b15bd576a920c03093
Make the copy member of StringRef/ArrayRef generic wrt allocators.

Doesn't make sense to restrict this to BumpPtrAllocator. While there
replace an explicit loop with std::equal. Some standard libraries know
how to compile this down to a ::memcmp call if possible.

llvm-svn: 206615
llvm/include/llvm/ADT/ArrayRef.h
llvm/include/llvm/ADT/StringRef.h
llvm/include/llvm/CodeGen/MachineValueType.h