This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug translator/12770] New: loc2c generates an unsupported deref(8,...) on i686


http://sourceware.org/bugzilla/show_bug.cgi?id=12770

           Summary: loc2c generates an unsupported deref(8,...) on i686
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap@sourceware.org
        ReportedBy: jistone@redhat.com


On 32-bit x86, our deref macro only supports accessed of size 1, 2, or 4. 
However, on kernel-2.6.35.12-90.fc14.i686.PAE, the following test generates a
deref-8 call which can't be resolved:

$ stap -e 'probe kernel.function("pagemap_hugetlb_range") { println($pte->pte)
}' -p2 --vp 01
# functions
_dwarf_tvar_get_pte_0:long ()
%{
#define fetch_register k_fetch_register
#define store_register k_store_register
{
  {
    uint32_t addr;
    { // DWARF expression: 0x50
    { uint32_t value = fetch_register (0); addr = value; }
    }
    { uint64_t value = deref (8, addr); THIS->__retvalue = value; }
  }
  goto out;
if (0) goto deref_fault;
deref_fault:
  goto out;
}
/* pure *//* unprivileged */
#undef fetch_register

#undef store_register
%}
# probes
kernel.function("pagemap_hugetlb_range@fs/proc/task_mmu.c:655") /*
pc=_stext+0x119935 */ /* <- kernel.function("pagemap_hugetlb_range") */
println(_dwarf_tvar_get_pte_0())
Pass 2: analyzed script: 1 probe(s), 1 function(s), 0 embed(s), 0 global(s)
using 185848virt/104624res/77516shr kb, in 700usr/110sys/829real ms.


$ stap -e 'probe kernel.function("pagemap_hugetlb_range") { println($pte->pte)
}' -p4 --vp 0001
WARNING: "__get_user_bad"
[/tmp/stapwpN5rU/stap_b871dcd3c99d49de3d49b1b1faf1614a_1195.ko] undefined!
/home/jistone/.systemtap/cache/b8/stap_b871dcd3c99d49de3d49b1b1faf1614a_1195.ko
Pass 4: compiled C into "stap_b871dcd3c99d49de3d49b1b1faf1614a_1195.ko" in
2240usr/1520sys/4287real ms.


$ stap -e 'probe kernel.function("pagemap_hugetlb_range") { println($pte->pte)
}' --vp 00001
Pass 5: starting run.
Error inserting module
'/tmp/stapvnS0Fr/stap_b871dcd3c99d49de3d49b1b1faf1614a_1195.ko': Unknown symbol
in module
Error, 'stap_b871dcd3c99d49de3d49b1b1faf1614a_1195' is not a zombie systemtap
module.
Retrying, after attempted removal of module
stap_b871dcd3c99d49de3d49b1b1faf1614a_1195 (rc -5)
Error inserting module
'/tmp/stapvnS0Fr/stap_b871dcd3c99d49de3d49b1b1faf1614a_1195.ko': Unknown symbol
in module
Pass 5: run completed in 0usr/20sys/91real ms.
Pass 5: run failed.  Try again with another '--vp 00001' option.
$ dmesg | tail -n1
[ 1495.344015] stap_b871dcd3c99d49de3d49b1b1faf1614a_1195: Unknown symbol
__get_user_bad (err 0)

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]