Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 24 Apr 2018 08:09:59 +0000
From:      bugzilla-noreply@freebsd.org
To:        toolchain@FreeBSD.org
Subject:   [Bug 227723] clang 6.0 breaks php56/opcache
Message-ID:  <bug-227723-29464-wSOzrR3udg@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-227723-29464@https.bugs.freebsd.org/bugzilla/>
References:  <bug-227723-29464@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D227723

--- Comment #3 from lampa@fit.vutbr.cz ---
Patch seems to be ok. I've only changed installed header files in
/usr/local/include/php/Zend, recompiled/reinstalled opcache, restarted apac=
he
and it runs.
I've reduced problem to:

#include <stdio.h>
#include <stdlib.h>

#define EX_TMP_VAR(ex, n)         ((temp_variable*)(((char*)(ex)) +
((int)(n))))
#define EX_TMP_VAR_NUM(ex, n)  (EX_TMP_VAR(ex, 0) - (1 + (n)))
#define VAR_NUM(v) ((unsigned int)(EX_TMP_VAR_NUM(0, 0) - EX_TMP_VAR(0, v)))

typedef struct TV {
        long tmp;
        char tmp3[30];
} temp_variable;

int num;

int main()
{
        printf("%x\n", VAR_NUM(-100));
        return 0;
}

cc -O2 t.c
f999999c
clang50 -O2 t.c
1
gcc -O2 t.c
1

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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-227723-29464-wSOzrR3udg>