Skip to content

Commit f0b5fd2

Browse files
authored
User/jbatista/remove isnormal dependencies02 (microsoft#4692)
There are some other functions that are found in the IsNormal HLK test that are defined and declared in the DxcTestUtils files. This is bad because DxcTestUtils takes a dependency on LLVM. This PR gets rid of the rest of the functions that don't need to depend on an llvm include, but are necessary to allow IsNormal to function, and moves the functions to HLSLTestUtils.h. Hopefully after this PR, IsNormal will be able to run when copied to other repos. These functions and all their dependent functions were moved to HLSLTestUtils.h: -VerifyCompileOK -DisassembleProgram -AssembleToContainer
1 parent c31ea79 commit f0b5fd2

File tree

6 files changed

+626
-575
lines changed

6 files changed

+626
-575
lines changed

include/dxc/Test/DxcTestUtils.h

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -156,10 +156,8 @@ class FileRunTestResult {
156156
LPCWSTR dumpName = nullptr);
157157
};
158158

159-
void AssembleToContainer(dxc::DxcDllSupport &dllSupport, IDxcBlob *pModule, IDxcBlob **pContainer);
160159
std::string BlobToUtf8(_In_ IDxcBlob *pBlob);
161160
std::wstring BlobToWide(_In_ IDxcBlob *pBlob);
162-
void CheckOperationSucceeded(IDxcOperationResult *pResult, IDxcBlob **ppBlob);
163161
bool CheckOperationResultMsgs(IDxcOperationResult *pResult,
164162
llvm::ArrayRef<LPCSTR> pErrorMsgs,
165163
bool maySucceedAnyway, bool bRegex);
@@ -171,10 +169,7 @@ bool CheckMsgs(const LPCSTR pText, size_t TextCount, const LPCSTR *pErrorMsgs,
171169
bool CheckNotMsgs(const LPCSTR pText, size_t TextCount, const LPCSTR *pErrorMsgs,
172170
size_t errorMsgCount, bool bRegex);
173171
void GetDxilPart(dxc::DxcDllSupport &dllSupport, IDxcBlob *pProgram, IDxcBlob **pDxilPart);
174-
std::string DisassembleProgram(dxc::DxcDllSupport &dllSupport, IDxcBlob *pProgram);
175172
void SplitPassList(LPWSTR pPassesBuffer, std::vector<LPCWSTR> &passes);
176-
void MultiByteStringToBlob(dxc::DxcDllSupport &dllSupport, const std::string &val, UINT32 codePoint, _Outptr_ IDxcBlob **ppBlob);
177-
void MultiByteStringToBlob(dxc::DxcDllSupport &dllSupport, const std::string &val, UINT32 codePoint, _Outptr_ IDxcBlobEncoding **ppBlob);
178173
void ReplaceDisassemblyText(llvm::ArrayRef<LPCSTR> pLookFors,
179174
llvm::ArrayRef<LPCSTR> pReplacements, bool bRegex,
180175
std::string &disassembly);
@@ -186,17 +181,8 @@ void ReplaceDisassemblyText(llvm::ArrayRef<LPCSTR> pLookFors,
186181
void ReplaceDisassemblyTextWithRegex(llvm::ArrayRef<LPCSTR> pLookFors,
187182
llvm::ArrayRef<LPCSTR> pReplacements,
188183
std::string &disassembly);
189-
void Utf8ToBlob(dxc::DxcDllSupport &dllSupport, const std::string &val, _Outptr_ IDxcBlob **ppBlob);
190-
void Utf8ToBlob(dxc::DxcDllSupport &dllSupport, const std::string &val, _Outptr_ IDxcBlobEncoding **ppBlob);
191-
void Utf8ToBlob(dxc::DxcDllSupport &dllSupport, const char *pVal, _Outptr_ IDxcBlobEncoding **ppBlob);
192184
void WideToBlob(dxc::DxcDllSupport &dllSupport, const std::wstring &val, _Outptr_ IDxcBlob **ppBlob);
193185
void WideToBlob(dxc::DxcDllSupport &dllSupport, const std::wstring &val, _Outptr_ IDxcBlobEncoding **ppBlob);
194-
void VerifyCompileOK(dxc::DxcDllSupport &dllSupport, LPCSTR pText,
195-
LPWSTR pTargetProfile, LPCWSTR pArgs,
196-
_Outptr_ IDxcBlob **ppResult);
197-
void VerifyCompileOK(dxc::DxcDllSupport &dllSupport, LPCSTR pText,
198-
LPWSTR pTargetProfile, std::vector<LPCWSTR> &args,
199-
_Outptr_ IDxcBlob **ppResult);
200186

201187
HRESULT GetVersion(dxc::DxcDllSupport& DllSupport, REFCLSID clsid, unsigned &Major, unsigned &Minor);
202188
bool ParseTargetProfile(llvm::StringRef targetProfile, llvm::StringRef &outStage, unsigned &outMajor, unsigned &outMinor);

0 commit comments

Comments
 (0)