[Webkit-unassigned] [Bug 111660] New: isVFPPresent failed to detect vfp3

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Mar 6 18:43:55 PST 2013


https://bugs.webkit.org/show_bug.cgi?id=111660

           Summary: isVFPPresent failed to detect vfp3
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Android
        OS/Version: Android
            Status: UNCONFIRMED
          Severity: Critical
          Priority: P1
         Component: JavaScriptCore
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: manjian2006 at gmail.com


Currently,the ARM family assemblers only support vfp3.But the function isVFPPresent just determines if we want to use vfp by checking HWCAP_VFP.
    int fd = open("/proc/self/auxv", O_RDONLY);
    if (fd > 0) {
        Elf32_auxv_t aux;
        while (read(fd, &aux, sizeof(Elf32_auxv_t))) {
            if (aux.a_type == AT_HWCAP) {
                close(fd);
                return aux.a_un.a_val & HWCAP_VFP;
            }
        }
        close(fd);
    }

This flag is on whenever the cpu has a vfp.But for armv5 family cpus,they just have vfp,not vfp3.So this will cause crash on these machines.
You should change HWCAP_VFP to HWCAP_VFPv3.
As the Linux kernel source arch/arm/vfp/vfpmodule.c descripts:

#ifdef CONFIG_VFPv3
        if (VFP_arch >= 2) {
            elf_hwcap |= HWCAP_VFPv3;

            /*
             * Check for VFPv3 D16. CPUs in this configuration
             * only have 16 x 64bit registers.
             */
            if (((fmrx(MVFR0) & MVFR0_A_SIMD_MASK)) == 1)
                elf_hwcap |= HWCAP_VFPv3D16;
        }
#endif

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list