[Lldb-commits] [PATCH] D102140: [ppc64le] [lldb] [testsuite] Fix false FAILs on ppc64* with no hw watchpoints
David Spickett via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Wed May 19 07:33:53 PDT 2021
DavidSpickett added a comment.
Is there any command we can run to directly get the number of h/w watchpoints?
I'm thinking that a lot of these are:
try:
doThing()
except:
if we got this specific error
Then you could have this at the start of each test instead:
if not self.HasWatchpoints():
self.skipTest(...)
Where HasWatchpoints runs that command. If there isn't a specific command you could do something silly like watch `main` and see if it succeeds then remove the watchpoint.
Failing that you could make some `skipIfErrorNoWatchpoints(err)` just to reduce the duplication.
================
Comment at: lldb/test/API/commands/watchpoints/hello_watchpoint/TestMyFirstWatchpoint.py:68
+ except:
+ if self.getArchitecture() == 'powerpc64le' \
+ and "\nerror: Target supports (0) hardware watchpoint slots.\n" \
----------------
Is the arch check here needed, also should it include powerpc64be? (not very familiar with powerpc but your title says `ppc64*`)
I don't think it would harm to not check the arch.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D102140/new/
https://reviews.llvm.org/D102140
More information about the lldb-commits
mailing list