[all-commits] [llvm/llvm-project] 8a0f0e: [lldb/test] Tweak libcxx string test on Apple+ARM ...

Vedant Kumar via All-commits all-commits at lists.llvm.org
Fri Feb 21 15:54:51 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 8a0f0e2656abf76b771037c6543caf9a31744120
      https://github.com/llvm/llvm-project/commit/8a0f0e2656abf76b771037c6543caf9a31744120
  Author: Vedant Kumar <vsk at apple.com>
  Date:   2020-02-21 (Fri, 21 Feb 2020)

  Changed paths:
    M lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/string/TestDataFormatterLibcxxString.py

  Log Message:
  -----------
  [lldb/test] Tweak libcxx string test on Apple+ARM devices

On Apple platforms, is __arm__ isn't defined and we're not on Intel, we use an
alternate std::string layout. I.e., the libcxx string test fails on phones
because the hand-crafted "garbage" string structs are actually valid strings.

See:

```
  // _LIBCPP_ALTERNATE_STRING_LAYOUT is an old name for
  // _LIBCPP_ABI_ALTERNATE_STRING_LAYOUT left here for backward compatibility.
  #if (defined(__APPLE__) && !defined(__i386__) && !defined(__x86_64__) &&       \
       (!defined(__arm__) || __ARM_ARCH_7K__ >= 2)) ||                           \
      defined(_LIBCPP_ALTERNATE_STRING_LAYOUT)
  #define _LIBCPP_ABI_ALTERNATE_STRING_LAYOUT
  #endif
```

Disable inspection of the garbage structs on Apple+ARM devices.




More information about the All-commits mailing list