mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-13 04:38:24 +00:00
The computation of string length is not that complicated. Fix it, again. :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130967 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -140,7 +140,7 @@ namespace {
|
||||
// A GCOV string is a length, followed by a NUL, then between 0 and 3 NULs
|
||||
// padding out to the next 4-byte word. The length is measured in 4-byte
|
||||
// words including padding, not bytes of actual string.
|
||||
return (s.size() + 5) / 4;
|
||||
return (s.size() / 4) + 1;
|
||||
}
|
||||
|
||||
void writeGCOVString(StringRef s) {
|
||||
|
Reference in New Issue
Block a user