[PATCH] D115702: [LNT] Fix profile assigning to tests
Thomas Preud'homme via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 19 01:51:27 PST 2022
thopre accepted this revision.
thopre added inline comments.
This revision is now accepted and ready to land.
================
Comment at: lnt/server/db/testsuitedb.py:1044
for test_data in tests_data:
+ if len(test_data) == 2 and 'profile' in test_data:
+ # Ignore for now profile data without other metrics
----------------
slydiman wrote:
> thopre wrote:
> > slydiman wrote:
> > > thopre wrote:
> > > > If a profile is determined by having the name ends in .profile I'd prefer to check that explicitely (i.e. `test_data['name'].endswith('profie')`)
> > > It will not work because __init__.py (line 593) removes '.profile' from the name during preprocessing.
> > One more reason to rewrite this test.
> What test do you mean? This code works just fine.
>
> You suggested
>
> > If a profile is determined by having the name ends in .profile I'd prefer to check that explicitely (i.e. test_data['name'].endswith('profie'))
>
> But it will not work because lnt/testing/__init__.py (line 593) converts JSON data v1 to v2:
>
> ```
> {“Data”: [ “base64_encoded_profile_data” ], “Name”: “nts.SomeTest.profile”}
> ```
> to
> ```
> {“profile”: [ “base64_encoded_profile_data” ], “name”: “nts.SomeTest”}
> ```
Ah my bad, hadn't realized it gets transformed to a dictionary with a "profile" key. I thought it was looking for "profile" in one of the value. LGTM then.
Repository:
rLNT LNT
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D115702/new/
https://reviews.llvm.org/D115702
More information about the llvm-commits
mailing list