[Bug 264497] -fcf-protection causes 'illegal hardware instruction' on Geode

From: <bugzilla-noreply_at_freebsd.org>
Date: Mon, 06 Jun 2022 12:10:18 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=264497

            Bug ID: 264497
           Summary: -fcf-protection causes 'illegal hardware instruction'
                    on Geode
           Product: Base System
           Version: 13.1-RELEASE
          Hardware: i386
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: bugs@FreeBSD.org
          Reporter: kp@freebsd.org

I have an (old) Geode(TM) Integrated Processor by AMD PCS based i386 machine,
and noticed that sudo started crashing with 'illegal hardware instruction'.

I've narrowed it down to being triggered by the '-fcf-protection ' compiler
flag.

The following test code reproduces the issue:

#include <stdio.h>

int
main(void)
{
    printf("In main\n");
    return (0);
}

# cc -Wall -fcf-protection test.c -o t ; ./t
[7]    66939 illegal hardware instruction (core dumped)  ./t

-- 
You are receiving this mail because:
You are the assignee for the bug.