-
Notifications
You must be signed in to change notification settings - Fork 87
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FreeBSD support #68
base: master
Are you sure you want to change the base?
FreeBSD support #68
Conversation
On NetBSD/amd64 the build fails with:
(Please do not consider that blocking the pull request but it was pasted only for completeness per request regarding intel/media-driver#819, and I am not sure that I will be able to investigate further in the short term, sorry!) |
@iamleot, can you try again? NetBSD and OpenBSD don't have |
Hello Jan,
Jan Beich writes:
@iamleot, can you try again? NetBSD and OpenBSD don't have `ffsl` in libc.
Sure, I'll try this evening!
Thanks!
|
I can confirm that now it build successfully on NetBSD/amd64 and, last lines of tests:
Thank you! |
Any chance of this being merged at some point? It's blocking intel/media-driver#819. |
Another friendly ping |
@johnmach any chance to get it committed? These changes are being applied on FreeBSD ports tree for years now and proved working |
In file included from Source/GmmLib/ULT/GmmAuxTableULT.cpp:25: In file included from Source/GmmLib/ULT/./GmmAuxTableULT.h:33: /usr/include/malloc.h:3:2: error: "<malloc.h> has been replaced by <stdlib.h>" #error "<malloc.h> has been replaced by <stdlib.h>" ^
…ed here Source/GmmLib/Utility/GmmLog/GmmLog.cpp:36:10: fatal error: 'linux/limits.h' file not found #include <linux/limits.h> ^~~~~~~~~~~~~~~~
ld: error: unable to find library -ldl
In file included from Source/GmmLib/Platform/GmmGen11Platform.cpp:23: In file included from Source/GmmLib/inc/Internal/Common/GmmLibInc.h:35: In file included from Source/GmmLib/inc/External/Common/GmmCachePolicy.h:332: Source/GmmLib/inc/External/Common/GmmCachePolicyCommon.h:74:13: error: control reaches end of non-void function [-Werror,-Wreturn-type] } ^ Source/GmmLib/GlobalInfo/GmmInfo.cpp:600:1: error: non-void function does not return a value in all control paths [-Werror,-Wreturn-type] } ^ Source/GmmLib/GlobalInfo/GmmInfo.cpp:635:5: error: expected 'while' in do/while loop else ^ Source/GmmLib/GlobalInfo/GmmInfo.cpp:616:9: note: to match this 'do' do ^ Source/GmmLib/GlobalInfo/GmmInfo.cpp:803:18: error: qualified reference to 'Context' is a constructor name rather than a type in this context GmmLib::Context::Context() ^ Source/GmmLib/GlobalInfo/GmmInfo.cpp:804:5: error: expected ';' after expression : ClientType(), ^ [...]
In file included from Source/GmmLib/CachePolicy/GmmCachePolicy.cpp:23: In file included from Source/GmmLib/inc/Internal/Common/GmmLibInc.h:58: In file included from Source/GmmLib/inc/External/Common/GmmResourceInfo.h:91: In file included from Source/GmmLib/inc/External/Common/../Linux/GmmResourceInfoLin.h:26: In file included from Source/GmmLib/inc/External/Common/../Linux/../Common/GmmResourceInfoCommon.h:32: Source/GmmLib/inc/External/Common/GmmClientContext.h:59:5: error: unknown type name 'GMM_DEVICE_CALLBACKS_INT' GMM_DEVICE_CALLBACKS_INT *pDeviceCb; ^ Source/GmmLib/inc/External/Common/GmmClientContext.h:85:9: error: unknown type name 'GMM_DEVICE_CALLBACKS_INT' GMM_DEVICE_CALLBACKS_INT DeviceCB; //OS-specific defn: Will be used by Clients to send as input arguments. ^ Source/GmmLib/inc/External/Common/GmmClientContext.h:139:80: error: unknown type name 'GMM_DEVICE_CALLBACKS_INT' GMM_VIRTUAL GMM_PAGETABLE_MGR* GMM_STDCALL CreatePageTblMgrObject(GMM_DEVICE_CALLBACKS_INT* pDevCb, uint32_t TTFlags); ^ Source/GmmLib/inc/External/Common/GmmClientContext.h:154:57: error: unknown type name 'GMM_DEVICE_CALLBACKS_INT' GMM_DEVICE_CALLBACKS_INT* pDevCb, ^ In file included from Source/GmmLib/CachePolicy/GmmCachePolicy.cpp:23: In file included from Source/GmmLib/inc/Internal/Common/GmmLibInc.h:62: Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:56:5: error: unknown type name 'GMM_UMD_SYNCCONTEXT'; did you mean 'GMM_UMD_CONTEXT'? GMM_UMD_SYNCCONTEXT * UmdContext; // [in] pointer to thread-specific data, specifying BBQHandle/Fence etc ^~~~~~~~~~~~~~~~~~~ GMM_UMD_CONTEXT Source/GmmLib/inc/External/Common/GmmInfo.h:58:3: note: 'GMM_UMD_CONTEXT' declared here } GMM_UMD_CONTEXT; ^ In file included from Source/GmmLib/CachePolicy/GmmCachePolicy.cpp:23: In file included from Source/GmmLib/inc/Internal/Common/GmmLibInc.h:62: Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:72:9: error: unknown type name 'HANDLE' HANDLE BBQueueHandle; ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:75:21: error: unknown type name 'HANDLE' SyncInfoLin(HANDLE Handle, uint64_t Fence) {} ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:115:9: error: unknown type name 'GMM_DEVICE_CALLBACKS' GMM_DEVICE_CALLBACKS DeviceCb; //OS-specific defn: Will be used by Clients to send as input arguments for TR-TT APIs ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:116:9: error: unknown type name 'GMM_DEVICE_CALLBACKS_INT' GMM_DEVICE_CALLBACKS_INT DeviceCbInt; //OS-specific defn: Will be used internally GMM lib ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:117:9: error: unknown type name 'GMM_TRANSLATIONTABLE_CALLBACKS' GMM_TRANSLATIONTABLE_CALLBACKS TTCb; //OS-specific defn ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:118:9: error: unknown type name 'HANDLE' HANDLE hCsr; // OCL per-device command stream receiver handle for aubcapture ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:121:25: error: unknown type name 'GMM_DEVICE_CALLBACKS_INT' GmmPageTableMgr(GMM_DEVICE_CALLBACKS_INT *, uint32_t TTFlags, GmmClientContext *pClientContextIn); // Allocates memory for indicate TT’s root-tables, initializes common node-pool ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:128:60: error: unknown type name 'HANDLE' GMM_VIRTUAL GMM_STATUS InitContextAuxTableRegister(HANDLE initialBBHandle, GMM_ENGINE_TYPE engType); //Clients call it to update Aux-Table pointer in context-image, engType reqd. if @ context level ^ Source/GmmLib/inc/External/Common/GmmPageTableMgr.h:133:46: error: unknown type name 'GMM_UMD_SYNCCONTEXT'; did you mean 'GMM_UMD_CONTEXT'? GMM_VIRTUAL void __ReleaseUnusedPool(GMM_UMD_SYNCCONTEXT *UmdContext); ^~~~~~~~~~~~~~~~~~~ GMM_UMD_CONTEXT Source/GmmLib/inc/External/Common/GmmInfo.h:58:3: note: 'GMM_UMD_CONTEXT' declared here } GMM_UMD_CONTEXT; ^
In file included from media_driver/agnostic/common/cm/cm_hal_hashtable.cpp:36: In file included from media_driver/agnostic/common/cm/cm_hal_hashtable.h:29: In file included from media_driver/agnostic/common/os/mos_os.h:31: In file included from media_driver/linux/common/os/media_skuwa_specific.h:32: In file included from media_driver/linux/common/os/linux_shadow_skuwa.h:31: In file included from /usr/local/include/igdgmm/GmmLib/inc/GmmLib.h:30: /usr/local/include/igdgmm/inc/portable_compiler.h:33:13: error: '__fastcall' macro redefined [-Werror,-Wmacro-redefined] #define __fastcall ^ /usr/include/sys/cdefs.h:372:9: note: previous definition is here #define __fastcall __attribute__((__fastcall__)) ^
In file included from Source/GmmLib/TranslationTable/GmmAuxTable.cpp:30: Source/GmmLib/TranslationTable/../TranslationTable/GmmUmdTranslationTable.h: In function ‘int _BitScanForward(uint32_t*, uint32_t)’: Source/GmmLib/TranslationTable/../TranslationTable/GmmUmdTranslationTable.h:63:9: error: ‘ffsl’ was not declared in this scope i = ffsl(mask); ^~~~ Source/GmmLib/TranslationTable/../TranslationTable/GmmUmdTranslationTable.h:63:9: note: suggested alternative: ‘ffs’ i = ffsl(mask); ^~~~ ffs
As GitHub auto-closes PRs on fork removal I'm transfering my gmmlib fork to @rosorio per intel/media-driver#1785. Otherwise, this PR will have to be duplicated like what happened with media-driver... except no new changes are required for now. |
Runtime tested on Skylake via Media Driver and NEO packages.
Build logs
Tests output
Note, to avoid regressing build in future consider FreeBSD-friendly CI.