Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpo-33926: enable GDB tests on Travis CI #14395

Merged
merged 2 commits into from Jun 27, 2019
Merged

Conversation

Copy link
Contributor

@jdemeyer jdemeyer commented Jun 26, 2019

.travis.yml Show resolved Hide resolved
@tirkarthi
Copy link

@tirkarthi tirkarthi commented Jun 27, 2019

I guess this also resolves https://bugs.python.org/issue33926 . Thanks.

.travis.yml Outdated
# Use -O3 because we don't use debugger on Travis-CI
- CFLAGS="-I${OPENSSL_DIR}/include -O3"
# Use -Og because we want to run all GDB tests
- CFLAGS="-I${OPENSSL_DIR}/include -Og"
Copy link
Member

@methane methane Jun 27, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- CFLAGS="-I${OPENSSL_DIR}/include -Og"
- CFLAGS="-I${OPENSSL_DIR}/include"

.travis.yml Outdated
@@ -14,8 +14,8 @@ env:
- OPENSSL=1.1.1c
- OPENSSL_DIR="$HOME/multissl/openssl/${OPENSSL}"
- PATH="${OPENSSL_DIR}/bin:$PATH"
# Use -O3 because we don't use debugger on Travis-CI
- CFLAGS="-I${OPENSSL_DIR}/include -O3"
# Use -Og because we want to run all GDB tests
Copy link
Member

@methane methane Jun 27, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this comment line.

@bedevere-bot
Copy link

@bedevere-bot bedevere-bot commented Jun 27, 2019

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@jdemeyer
Copy link
Author

@jdemeyer jdemeyer commented Jun 27, 2019

@methane: we need to use -O0 or -Og as optimization flag. This is because gdb tests are not run when CPython is compiled with the default -O3 level (IMHO, this is in itself a bug, however fixing that is more controversial that I expected, see #14331).

@jdemeyer
Copy link
Author

@jdemeyer jdemeyer commented Jun 27, 2019

I guess this also resolves https://bugs.python.org/issue33926 . Thanks.

In fact, it fixes exactly that. So I'm changing the bpo number here.

@jdemeyer jdemeyer changed the title bpo-37382: enable GDB tests on Travis CI bpo-33926: enable GDB tests on Travis CI Jun 27, 2019
@methane
Copy link

@methane methane commented Jun 27, 2019

@methane: we need to use -O0 or -Og as optimization flag.

When configure --with-pydebug is used, it is set automatically. No need to set it explicitly.

@tirkarthi
Copy link

@tirkarthi tirkarthi commented Jun 27, 2019

@jdemeyer Can you please change the issue number in PR description from 32926 to 33926? I guess the bot keeps linking this PR to the issue 32926 for every comment made in this PR.

@jdemeyer
Copy link
Author

@jdemeyer jdemeyer commented Jun 27, 2019

When configure --with-pydebug is used, it is set automatically.

OK, let's test that.

@jdemeyer jdemeyer changed the title bpo-33926: enable GDB tests on Travis CI [DO-NOT-MERGE] bpo-33926: enable GDB tests on Travis CI Jun 27, 2019
@jdemeyer jdemeyer changed the title [DO-NOT-MERGE] bpo-33926: enable GDB tests on Travis CI bpo-33926: enable GDB tests on Travis CI Jun 27, 2019
@jdemeyer
Copy link
Author

@jdemeyer jdemeyer commented Jun 27, 2019

OK, this seems to work. I have made the requested changes; please review again

@bedevere-bot
Copy link

@bedevere-bot bedevere-bot commented Jun 27, 2019

Thanks for making the requested changes!

@methane: please review the changes made to this pull request.

@methane methane merged commit 667eaff into python:master Jun 27, 2019
5 checks passed
@miss-islington
Copy link

@miss-islington miss-islington commented Jun 27, 2019

Thanks @jdemeyer for the PR, and @methane for merging it 🌮🎉.. I'm working now to backport this PR to: 3.8.
🐍🍒🤖

@bedevere-bot
Copy link

@bedevere-bot bedevere-bot commented Jun 27, 2019

GH-14420 is a backport of this pull request to the 3.8 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this issue Jun 27, 2019
(cherry picked from commit 667eaff)

Co-authored-by: Jeroen Demeyer <J.Demeyer@UGent.be>
@tirkarthi
Copy link

@tirkarthi tirkarthi commented Jun 27, 2019

Does this change have any noticeable impact on CI timing? The merge run happened for 20 mins which used to be 10-12 mins earlier. The backport PR also completes in around 20 minutes.

miss-islington added a commit that referenced this issue Jun 27, 2019
(cherry picked from commit 667eaff)

Co-authored-by: Jeroen Demeyer <J.Demeyer@UGent.be>
@methane
Copy link

@methane methane commented Jun 27, 2019

Does this change have any noticeable impact on CI timing? The merge run happened for 20 mins which used to be 10-12 mins earlier. The backport PR also completes in around 20 minutes.

Yes, it affects. I will compare the time of -Og and -O0.

@methane
Copy link

@methane methane commented Jun 27, 2019

-Og
real    5m3.236s
user    16m29.552s
sys     0m57.023s

-O0
real    6m56.909s
user    30m5.529s
sys     1m0.605s

@vstinner
Copy link

@vstinner vstinner commented Jun 27, 2019

Does this change have any noticeable impact on CI timing? The merge run happened for 20 mins which used to be 10-12 mins earlier. The backport PR also completes in around 20 minutes.

  • On PR #14390: "CPython tests" job took 15 min 39 sec
  • On this PR, it took 22 min 23 sec: +6 min 44 sec, it's quite significant

@vstinner
Copy link

@vstinner vstinner commented Jun 27, 2019

  • PR #14390: "Total duration: 11 min 8 sec" just for tests (regrtest)
  • On this PR: "Total duration: 20 min 30 sec": +9 min 22 sec

It's 1.8x slower.

@vstinner
Copy link

@vstinner vstinner commented Jun 27, 2019

Previously, we used -O3:

commit 8ff53564730f7ba503f5ad94418c309c48e8516d
Author: INADA Naoki <methane@users.noreply.github.com>
Date:   Sat Feb 10 20:35:17 2018 +0900

    travis: Use -O3 option (GH-5599)
    
    We don't use debugger on Travis.

Is it really useful to make the pre-commit CI almost 2x slower just because of test_gdb? We already have a large fleet of post-commit buildbots which run test_gdb.

@methane
Copy link

@methane methane commented Jun 27, 2019

@vstinner
Copy link

@vstinner vstinner commented Jun 27, 2019

-Og isn't the default when building using --with-pydebug?

16 min 52 sec total, "Total duration: 12 min 4 sec" just for the tests, looks close to what we had using -O3. If test_gdb still pass, we should definitively use -Og :-) So yeah for #14423 :-)

@jdemeyer jdemeyer deleted the travis_gdb branch Jun 27, 2019
LorenzMende pushed a commit to LorenzMende/cpython that referenced this issue Aug 11, 2019
lisroach pushed a commit to lisroach/cpython that referenced this issue Sep 10, 2019
DinoV pushed a commit to DinoV/cpython that referenced this issue Jan 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants