Bug 1377249
Summary: | -fprofile-generate leads in root-owned files | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Harald Reindl <h.reindl> |
Component: | gcc | Assignee: | Jakub Jelinek <jakub> |
Status: | CLOSED INSUFFICIENT_DATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | 24 | CC: | davejohansen, jakub, jwakely, law, mpolacek |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2016-10-12 13:33:47 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Harald Reindl
2016-09-19 09:51:31 UTC
GCC has not way to become root, so this must be an issue with rpmbuild or your environment. i thought so too in fact it does and that sounds like something is running with suid in case of profile guided optimization because when %pgo_build is 0 all is fine # build php with 'profile-guided-optimization' when enabled %if %pgo_build echo "PROFILE-GUIDED-OPTIMIZATION: Stage 1" make %{?_smp_mflags} prof-gen /rpmbuild/PHP-PGO/profile.sh $PWD make clean echo "PROFILE-GUIDED-OPTIMIZATION: Stage 2" make %{?_smp_mflags} prof-use %else make %{?_smp_mflags} %endif The *.gcda files aren't written by gcc, but by the application you're testing (when compiled/linked with -fprofile-generate). It uses whatever uid the process has. Perhaps you are dlopening your -fprofile-generate built library into some suid app or something similar? In any case, there is nothing that can be done about it on the gcc side. while i have no idea why this is currently not reproduceable and all seems to working fine without any changes in the php.spec or involved scripts there where *in fact* also non-gcda files like .o owned by root and the whole process is started in a ssh session with a restricted user very strange and that it stopped with this behavior without knowing why don't make me terrible happy - the "don't know why" part especially |