[lldb/test] Tweak libcxx string test on Apple+ARM devices
authorVedant Kumar <vsk@apple.com>
Fri, 21 Feb 2020 23:21:19 +0000 (15:21 -0800)
committerVedant Kumar <vsk@apple.com>
Fri, 21 Feb 2020 23:54:38 +0000 (15:54 -0800)
commit8a0f0e2656abf76b771037c6543caf9a31744120
tree5bde58372954c3fb00c6bf877c969dbb9d94ef20
parent75af9da755721123e62b45cd0bc0c5e688a9722a
[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.
lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/string/TestDataFormatterLibcxxString.py