Skip to content

dev-cmd/prof: prevent from running on Apple Silicon#10691

Merged
dtrodrigues merged 1 commit intoHomebrew:masterfrom
dtrodrigues:prof-silicon
Feb 25, 2021
Merged

dev-cmd/prof: prevent from running on Apple Silicon#10691
dtrodrigues merged 1 commit intoHomebrew:masterfrom
dtrodrigues:prof-silicon

Conversation

@dtrodrigues
Copy link
Copy Markdown
Member

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew style with your changes locally?
  • Have you successfully run brew typecheck with your changes locally?
  • Have you successfully run brew tests with your changes locally?

The prof command does not currently work on Apple silicon

$ brew prof readall
Traceback (most recent call last):
	7: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/bin/ruby-prof:23:in `<main>'
	6: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/bin/ruby-prof:23:in `load'
	5: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/bin/ruby-prof:4:in `<top (required)>'
	4: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
	3: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
	2: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/lib/ruby-prof.rb:7:in `<top (required)>'
	1: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load such file -- 2.6/ruby_prof.so (LoadError)
	7: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/bin/ruby-prof:23:in `<main>'
	6: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/bin/ruby-prof:23:in `load'
	5: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/bin/ruby-prof:4:in `<top (required)>'
	4: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
	3: from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
	2: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/lib/ruby-prof.rb:5:in `<top (required)>'
	1: from /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/lib/ruby-prof.rb:9:in `rescue in <top (required)>'
/opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/lib/ruby-prof.rb:9:in `require_relative': dlopen(/opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/ext/ruby_prof/ruby_prof.bundle, 0x0009): missing compatible arch in /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/ext/ruby_prof/ruby_prof.bundle - /opt/homebrew/Library/Homebrew/vendor/bundle/ruby/2.6.0/gems/ruby-prof-1.4.3/ext/ruby_prof/ruby_prof.bundle (LoadError)

@BrewTestBot
Copy link
Copy Markdown
Contributor

Review period will end on 2021-02-25 at 14:05:57 UTC.

@BrewTestBot BrewTestBot added the waiting for feedback Merging is blocked until sufficient time has passed for review label Feb 24, 2021
@BrewTestBot BrewTestBot removed the waiting for feedback Merging is blocked until sufficient time has passed for review label Feb 25, 2021
@BrewTestBot
Copy link
Copy Markdown
Contributor

Review period ended.

@dtrodrigues dtrodrigues merged commit a625948 into Homebrew:master Feb 25, 2021
@wrobelda
Copy link
Copy Markdown
Contributor

wrobelda commented Mar 6, 2021

@dtrodrigues are these issues reported upstream somewhere? I couldn't find anything related in for either of the two profilers affected (ruby-prof and stackprof).

@Bo98
Copy link
Copy Markdown
Member

Bo98 commented Mar 6, 2021

Yes: #10210 (comment). Reported to Apple under FB9002047.

It's a system Ruby bug rather than anything specific to these profilers. A fix has already been prepared - it's just unknown exactly which macOS update it will land in.

@dtrodrigues
Copy link
Copy Markdown
Member Author

It's not an issue with the gem itself, but rather an issue with native gems using the system ruby on Apple Silicon which has been reported to Apple: #10210 (comment)

@wrobelda
Copy link
Copy Markdown
Contributor

wrobelda commented Mar 6, 2021

Explains why I couldn't find it. Thank you both for answering almost simultaneously.

@BrewTestBot BrewTestBot added the outdated PR was locked due to age label Apr 5, 2021
@Homebrew Homebrew locked as resolved and limited conversation to collaborators Apr 5, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

outdated PR was locked due to age

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants