adsr / phpspy

low-overhead sampling profiler for PHP 7+

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Aarch64 support

Jongy opened this issue · comments

Is Aarch64 supported? The README mentions x86_64 explicitly but I didn't find any x86 reference in the code, though. I didn't try building for Aarch64 so far. I'll post here if I try.

I'd like to enable phpspy for our Aarch64 gProfiler build.

I tried building phpspy on an Aarch64 Ubuntu 20.04 and it just worked 🤷

make test output on Aarch64:

TEST tests/test_varpeek.sh
process_vm_readv: No such process
  OK   varpeek        
process_vm_readv: No such process
  OK   varpeek        

TEST tests/test_pgrep_time_limit.sh
main_pgrep finished gracefully
  OK   frame_1        
  OK   frame_0        
main_pgrep finished gracefully
  OK   nothing

TEST tests/test_pgrep_trace_limit.sh
main_pgrep finished gracefully
  OK   frame_1        
  OK   frame_0        

TEST tests/test_time_limit.sh
  OK   include_sleep

TEST tests/test_child.sh
  OK   req_uri        
  ERR  req_ts         
expected=^# ts = \d+\.\d+$

actual=
0 usleep <internal>:-1
1 <main> <internal>:-1
# uri = -
# path = Standard input code
# qstring = -
# cookie = -
# ts = -nan

TEST tests/test_verbose.sh
  OK   verbose_pid    
  OK   frame_1        
  OK   verbose_ts     
  OK   frame_0        

TEST tests/test_mem.sh
  SKIP alloc_globals symbol not found

TEST tests/test_flamegraph.sh
  OK   flamegraph

TEST tests/test_filter.sh
process_vm_readv: No such process
  OK   include_nanosleep
  OK   exclude_usleep
process_vm_readv: No such process
  OK   negate_include_nanosleep
  OK   negate_exclude_usleep

TEST tests/test_glopeek.sh
process_vm_readv: No such process
  OK   glopeek_server_new
  OK   glopeek_server_mod
  OK   glopeek_globals   
  OK   glopeek_server    
process_vm_readv: No such process
  OK   glopeek1       
  OK   glopeek2       

TEST tests/test_varpeek_range.sh
process_vm_readv: No such process
  OK   varpeek_range_a_3
  OK   varpeek_range_a_1
  OK   varpeek_range_b_4
  OK   varpeek_range_b_2

TEST tests/test_pid.sh
  OK   frame_1        
  OK   frame_0        

TEST tests/test_pgrep.sh
main_pgrep finished gracefully
  OK   frame_1        
  OK   frame_0        

TEST tests/test_buffer_full.sh
event_handler_fout_snprintf: Not enough space in buffer; truncating
  OK   frame_0        
  OK   no_frame_1 
event_handler_fout_snprintf: Not enough space in buffer; truncating
  OK   nothing

Passed 13 out of 14 tests
make: *** [Makefile:39: test] Error 1
commented

Glad to hear it works. I updated the README. Thank you for testing that @Jongy.

commented

Curious about global_request_time=-nan by the way. I wonder if that's legit or if phpspy has an issue with reading that double for some reason. Assuming the latter.

Probably the latter, yeah