LLVM使用void指针arg创建函数(LLVM create function with void pointer arg)
我想在LLVM中创建一个函数,该函数从存储指令获取指向任意内存的指针。 例如:
%x = alloca i32, align 4 %z = alloca i32*, align 8 store i32 123, i32* %x, align 4 store i32* %x, i32** %z, align 8
在这里,我想检测存储指令以调用具有类型i32 *和类型i32 **的内存指针的函数。 我只需要内存的“第一个指针”,我不需要取消引用指针或获取其类型信息。 所以,我需要一个类似于C中的void指针的数据类型。
我怎样才能在LLVM中做到这一点?
I want to create a function in LLVM that takes a pointer to arbitrary memory from store instructions. For example:
%x = alloca i32, align 4 %z = alloca i32*, align 8 store i32 123, i32* %x, align 4 store i32* %x, i32** %z, align 8
Here, I want to instrument the store instructions to invoke a function with the memory pointers which are once of type i32* and once of type i32**. I only need the "first pointer" to memory and I don't need to derenference the pointers or get its type information. So, I need a datatype that is similar to void pointers in C.
How can I do that in LLVM?
原文:https://stackoverflow.com/questions/39309708
相关问答
更多-
spαin怎么读[2023-09-06]
Spain 英[speɪn] 美[speɪn] n. 西班牙(欧洲国家); [例句]The game was transmitted live in Spain and Italy 这场比赛在西班牙和意大利进行了现场直播。 -
Nuget Update-Package错误地更新了程序集绑定重定向(Nuget Update-Package incorrectly updating assembly binding redirects)[2022-06-10]
跳过应用绑定重定向现在是NuGet 3.3.0中的一个选项: 问题#1147 Skip applying binding redirects is an option now in NuGet 3.3.0: Issue #1147 -
帮助SP和UDF?(Help with SP and UDF?)[2022-01-30]
存储过程 存储过程是由MySQL编写并执行的MySQL代码。 存储函数的示例 CREATE FUNCTION AreWeThereYet(Location integer) RETURNS boolean BEGIN Return 0; END 存储过程的示例 CREATE PROCEDURE InsertRow(A integer) BEGIN INSERT INTO table1 VALUES(A); END UDF的 UDF是C(++)或编译为.so (linux)或.dll (windo ... -
排序后,我不得不指定RelayState。 Sorted, I had to specify the RelayState.
-
我发现php的逻辑跟在我的例子中的SP php脚本,更明显的是,当我手动更改“stateId”时,出现如下错误:SimpleSAML_Error_Exception:This SP [ https:// domainname /simplesaml/module.php/saml/sp/metadata.php/default-sp]不是断言的有效受众。 候选人是:[com:vdenotaris:spring:sp] 这是非常奇怪的,超出了我的期望。 然后,我检查了SimpleSAMLphp文档中说明的“m ...
-
SAML支持前端通道绑定(您正在寻找的)和SP需要直接与IdP通信的反向通道绑定。 我见过的绝大多数部署使用前端通道,一切都通过用户的浏览器完成。 至于你的场景,是的,这是可能的。 我们经常在测试中使用它。 我已经看到企业只能在其本地网络中使用他们的IdP,但员工仍然可以访问外部的SaaS服务 - 因此您的情况确实有意义并且很常见。 至于您的问题(根据文档 ),NOSTATE通常是由域名更改,https到http重定向以及存储会话的任何问题引起的 - 例如在负载均衡设置中,您点击不共享会话的不同服务器。 我 ...
-
看一下exampleAuth exampleAuth:Static authsource 。 它会以特定用户身份自动登录 'example-static' => array( 'exampleauth:Static', 'uid' => array('testuser'), 'eduPersonAffiliation' => array('member', 'employee'), 'cn' => array('Test User'), ), 您可以像这样创建自己的模块,但 ...
-
绑定的URL是错误的:因为您的客户端使用PingFederate,所以URL应该是: 'Location' => "https://client.idp.url/idp/SSO.saml2", 用于POST以及重定向绑定。 您应该根据从客户端获得的元数据仔细检查:如果该元数据是由PingFederate自动生成的(因为它应该),它将不包含指向“内部” idp/startSSO.ping端点的链接,而是包含到公共SAML的链接2.0端点/idp/SSO.saml2 。 The URLs for the bi ...
-
您的实体ID应该是/apps/simplesamlphp/config/authsources.php https://以及元数据XML再次返回意外的http网址而不是地址中的entityID的https网址的原因是因为您可能没有生成证书,如果没有创建,你必须在cert/目录中创建一个自签名证书。 我在moodle使用auth_saml2插件时遇到了同样的情况。 当我通过链接https://simplesamlphp.org/docs/stable/simplesamlphp-sp在我的Centos中安装和 ...
-
从另一个sp获得sp值(Getting sp value from another sp)[2023-01-13]
您需要创建一个临时表,并插入其中。 declare @t table (id int) insert @t (id) exec myoldsp @parameters (你在尝试什么 - exec @autoid=myoldsp - 将返回return [val]语句中的值) You need to create a temporary table, and insert into it. declare @t table (id int) insert @t (id) exec myoldsp @p ...