Okay me again, I printed "pfm_current->get_event_name(i)" to stderr and it
clearly is an indexing problem (see below). Does this ring any bells?
Thanks,
Andrej
[EMAIL PROTECTED]:/usr/local/src/libpfm-3.5$ pfmon
event name: CPU_CLK_UNHALTED
event name: INST_RETIRED
event name: DATA_MEM_REFS
event name: DCU_LINES_IN
event name: DCU_M_LINES_IN
event name: DCU_M_LINES_OUT
event name: DCU_MISS_OUTSTANDING
event name: IFU_IFETCH
event name: IFU_IFETCH_MISS
event name: ITLB_MISS
event name: IFU_MEM_STALL
event name: ILD_STALL
event name: L2_IFETCH
event name: L2_ST
event name: L2_M_LINES_INM
event name: L2_RQSTS
event name: L2_ADS
event name: L2_DBUS_BUSY
event name: L2_DBUS_BUSY_RD
event name: BUS_DRDY_CLOCKS
event name: BUS_LOCK_CLOCKS
event name: BUS_REQ_OUTSTANDING
event name: BUS_TRANS_BRD
event name: BUS_TRANS_RFO
event name: BUS_TRANS_WB
event name: BUS_TRAN_IFETCH
event name: BUS_TRAN_INVAL
event name: BUS_TRAN_PWR
event name: BUS_TRANS_P
event name: BUS_TRANS_IO
event name: BUS_TRAN_DEF
event name: BUS_TRAN_BURST
event name: BUS_TRAN_ANY
event name: BUS_TRAN_MEM
event name: BUS_DATA_RECV
event name: BUS_BNR_DRV
event name: BUS_HIT_DRV
event name: BUS_HITM_DRV
event name: BUS_SNOOP_STALL
event name: FLOPS
event name: FP_COMP_OPS_EXE
event name: FP_ASSIST
event name: MUL
event name: DIV
event name: CYCLES_DIV_BUSY
event name: LD_BLOCKS
event name: SB_DRAINS
event name: MISALIGN_MEM_REF
event name: UOPS_RETIRED
event name: INST_DECODED
event name: HW_INT_RX
event name: CYCLES_INT_MASKED
event name: CYCLES_INT_PENDING_AND_MASKED
event name: BR_INST_RETIRED
event name: BR_MISS_PRED_RETIRED
event name: BR_TAKEN_RETIRED
event name: BR_MISS_PRED_TAKEN_RET
event name: BR_INST_DECODED
event name: BTB_MISSES
event name: BR_BOGUS
event name: BACLEARS
event name: RESOURCE_STALLS
event name: PARTIAL_RAT_STALLS
event name: SEGMENT_REG_LOADS
event name: L2_LD
event name: L2_LINES_IN
event name: L2_LINES_OUT
event name: L2_M_LINES_OUTM
event name: (null)
Segmentation fault (core dumped)
On Mon, Aug 25, 2008 at 9:51 PM, Andrej van der Zee <
[EMAIL PROTECTED]> wrote:
> Hi,
>
> I tried both -O0 and -O1 for both libprf and pfmon, but same segfault with
> same gdb-output.
>
> Hmmmm, if you recall the solution please tell me... Otherwise I will get
> into the sources tomorrow or so, when I find the time....
>
> Thanks,
> Andrej
>
>
>
> On Mon, Aug 25, 2008 at 9:23 PM, stephane eranian <[EMAIL PROTECTED]>wrote:
>
>> Andrej,
>>
>> On Mon, Aug 25, 2008 at 12:31 PM, Andrej van der Zee
>> <[EMAIL PROTECTED]> wrote:
>> > pfmon.c:1296
>> > #2 <signal handler called>
>> > #3 0xb7e4c283 in strlen () from /lib/tls/i686/cmov/libc.so.6
>> > #4 0xb7f34d61 in pfm_get_max_event_name_len (len=0xbfe2b330) at
>> > pfmlib_common.c:889
>> > #5 0x0804d880 in pfmon_initialize (argv=0xbfe2b434) at pfmon.c:1391
>> > #6 0x0804e60c in main (argc=1, argv=0xbfe2b434) at pfmon.c:1832
>> > (gdb) up 4
>> > #4 0xb7f34d61 in pfm_get_max_event_name_len (len=0xbfe2b330) at
>> > pfmlib_common.c:889
>> > 889 l = strlen(pfm_current->get_event_name(i));
>> > (gdb) list
>> > 884 return PFMLIB_ERR_NOINIT;
>> > 885 if (len == NULL)
>> > 886 return PFMLIB_ERR_INVAL;
>> > 887
>> > 888 for(i=0; i < pfm_current->pme_count; i++) {
>> > 889 l = strlen(pfm_current->get_event_name(i));
>> > 890 if (l > max) max = l;
>> > 891
>> > 892 num_masks = pfm_num_masks(i);
>> > 893 /*
>> > (gdb) print i
>> > $1 = 68
>> > (gdb)
>> >
>>
>> I have seen this problem with strlen() before. I thikn somebody
>> reported this error on MIPS.
>> Can you try compiling libpfm with a lower optimization level (-O1 or -O0)?
>>
>
>
>
> --
> Andrej van der Zee
> 2-40-19 Koenji-minami
> Suginami-ku, Tokyo
> 166-0003 JAPAN
> Mobile: 0031-(0)80-65251092
> Phone/Fax: 0031-(0)3-3318-3155
>
--
Andrej van der Zee
2-40-19 Koenji-minami
Suginami-ku, Tokyo
166-0003 JAPAN
Mobile: 0031-(0)80-65251092
Phone/Fax: 0031-(0)3-3318-3155
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
perfmon2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/perfmon2-devel