Note: GCC’s -fsanitize=undefined does not include this check; clang’s does. In include/my_global.h there is an attempt to fool clang, but I believe that it would lead to undefined behaviour as well:
In fact, some use of this led to crashes in clang -fsanitize=undefined builds, until MDEV-26272 was fixed.
Marko Mäkelä
added a comment - Note: GCC’s -fsanitize=undefined does not include this check; clang ’s does. In include/my_global.h there is an attempt to fool clang , but I believe that it would lead to undefined behaviour as well:
#define my_offsetof(TYPE, MEMBER) PTR_BYTE_DIFF(&((TYPE *)0x10)->MEMBER, 0x10)
In fact, some use of this led to crashes in clang -fsanitize=undefined builds, until MDEV-26272 was fixed.
People
Alexander Barkov
Roel Van de Paar
Votes:
0Vote for this issue
Watchers:
2Start watching this issue
Dates
Created:
Updated:
Resolved:
Git Integration
Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.
{"report":{"fcp":1134.3000001907349,"ttfb":268.2000002861023,"pageVisibility":"visible","entityId":131864,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"dc4025dd-7045-45ae-b1c9-89d2a003015f","navigationType":0,"readyForUser":1242.3000001907349,"redirectCount":0,"resourceLoadedEnd":759.9000000953674,"resourceLoadedStart":288.59999990463257,"resourceTiming":[{"duration":67,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":288.59999990463257,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":288.59999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":355.59999990463257,"responseStart":0,"secureConnectionStart":0},{"duration":69.59999990463257,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":289,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":289,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":358.59999990463257,"responseStart":0,"secureConnectionStart":0},{"duration":314.6000003814697,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":289.09999990463257,"connectEnd":289.09999990463257,"connectStart":289.09999990463257,"domainLookupEnd":289.09999990463257,"domainLookupStart":289.09999990463257,"fetchStart":289.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":365.40000009536743,"responseEnd":603.7000002861023,"responseStart":400.09999990463257,"secureConnectionStart":289.09999990463257},{"duration":447.7999997138977,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true&whisper-enabled=true","startTime":289.30000019073486,"connectEnd":289.30000019073486,"connectStart":289.30000019073486,"domainLookupEnd":289.30000019073486,"domainLookupStart":289.30000019073486,"fetchStart":289.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":365.90000009536743,"responseEnd":737.0999999046326,"responseStart":404,"secureConnectionStart":289.30000019073486},{"duration":119.30000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/a9324d6758d385eb45c462685ad88f1d-CDN/lu2cib/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":289.5,"connectEnd":289.5,"connectStart":289.5,"domainLookupEnd":289.5,"domainLookupStart":289.5,"fetchStart":289.5,"redirectEnd":0,"redirectStart":0,"requestStart":366.09999990463257,"responseEnd":408.80000019073486,"responseStart":406.09999990463257,"secureConnectionStart":289.5},{"duration":120.19999980926514,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":289.7000002861023,"connectEnd":289.7000002861023,"connectStart":289.7000002861023,"domainLookupEnd":289.7000002861023,"domainLookupStart":289.7000002861023,"fetchStart":289.7000002861023,"redirectEnd":0,"redirectStart":0,"requestStart":366.80000019073486,"responseEnd":409.90000009536743,"responseStart":406.59999990463257,"secureConnectionStart":289.7000002861023},{"duration":130.30000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":290,"connectEnd":290,"connectStart":290,"domainLookupEnd":290,"domainLookupStart":290,"fetchStart":290,"redirectEnd":0,"redirectStart":0,"requestStart":381.90000009536743,"responseEnd":420.30000019073486,"responseStart":417.5,"secureConnectionStart":290},{"duration":75.7000002861023,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2cib/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":290.09999990463257,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":290.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":365.80000019073486,"responseStart":0,"secureConnectionStart":0},{"duration":130.19999980926514,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":290.30000019073486,"connectEnd":290.30000019073486,"connectStart":290.30000019073486,"domainLookupEnd":290.30000019073486,"domainLookupStart":290.30000019073486,"fetchStart":290.30000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":383.30000019073486,"responseEnd":420.5,"responseStart":418.09999990463257,"secureConnectionStart":290.30000019073486},{"duration":81,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":290.5,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":290.5,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":371.5,"responseStart":0,"secureConnectionStart":0},{"duration":149.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/5d5e8fe91fbc506585e83ea3b62ccc4b-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":290.7000002861023,"connectEnd":290.7000002861023,"connectStart":290.7000002861023,"domainLookupEnd":290.7000002861023,"domainLookupStart":290.7000002861023,"fetchStart":290.7000002861023,"redirectEnd":0,"redirectStart":0,"requestStart":384.2000002861023,"responseEnd":440.2000002861023,"responseStart":418.90000009536743,"secureConnectionStart":290.7000002861023},{"duration":466,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":292,"connectEnd":292,"connectStart":292,"domainLookupEnd":292,"domainLookupStart":292,"fetchStart":292,"redirectEnd":0,"redirectStart":0,"requestStart":416.80000019073486,"responseEnd":758,"responseStart":750.3000001907349,"secureConnectionStart":292},{"duration":467.80000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":292.09999990463257,"connectEnd":292.09999990463257,"connectStart":292.09999990463257,"domainLookupEnd":292.09999990463257,"domainLookupStart":292.09999990463257,"fetchStart":292.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":444.59999990463257,"responseEnd":759.9000000953674,"responseStart":754.3000001907349,"secureConnectionStart":292.09999990463257},{"duration":292.59999990463257,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":814.3000001907349,"connectEnd":814.3000001907349,"connectStart":814.3000001907349,"domainLookupEnd":814.3000001907349,"domainLookupStart":814.3000001907349,"fetchStart":814.3000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":1072.5999999046326,"responseEnd":1106.9000000953674,"responseStart":1106.0999999046326,"secureConnectionStart":814.3000001907349},{"duration":303.59999990463257,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":1156.3000001907349,"connectEnd":1156.3000001907349,"connectStart":1156.3000001907349,"domainLookupEnd":1156.3000001907349,"domainLookupStart":1156.3000001907349,"fetchStart":1156.3000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":1429.0999999046326,"responseEnd":1459.9000000953674,"responseStart":1459.0999999046326,"secureConnectionStart":1156.3000001907349}],"fetchStart":0,"domainLookupStart":44,"domainLookupEnd":48,"connectStart":48,"connectEnd":71,"secureConnectionStart":57,"requestStart":72,"responseStart":268,"responseEnd":274,"domLoading":286,"domInteractive":1364,"domContentLoadedEventStart":1364,"domContentLoadedEventEnd":1430,"domComplete":2048,"loadEventStart":2048,"loadEventEnd":2048,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1307.5},{"name":"bigPipe.sidebar-id.end","time":1308.4000000953674},{"name":"bigPipe.activity-panel-pipe-id.start","time":1308.5},{"name":"bigPipe.activity-panel-pipe-id.end","time":1309.9000000953674},{"name":"activityTabFullyLoaded","time":1485.5999999046326}],"measures":[],"correlationId":"3809159de325fe","effectiveType":"4g","downlink":9.2,"rtt":0,"serverDuration":96,"dbReadsTimeInMs":12,"dbConnsTimeInMs":22,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
Note: GCC’s -fsanitize=undefined does not include this check; clang’s does. In include/my_global.h there is an attempt to fool clang, but I believe that it would lead to undefined behaviour as well:
In fact, some use of this led to crashes in clang -fsanitize=undefined builds, until
MDEV-26272was fixed.