diff --git a/docs/roadmap.html b/docs/roadmap.html
index c5d6161da..9af98e807 100644
--- a/docs/roadmap.html
+++ b/docs/roadmap.html
@@ -35,10 +35,10 @@
const path_to_root = "";
const default_light_theme = "light";
const default_dark_theme = "navy";
- window.path_to_searchindex_js = "searchindex-339ac392.js";
+ window.path_to_searchindex_js = "searchindex-07c17d47.js";
-
+
diff --git a/docs/searcher-c2a407aa.js b/docs/searcher-c2a407aa.js
index f92b02ab6..21d9a1e5a 100644
--- a/docs/searcher-c2a407aa.js
+++ b/docs/searcher-c2a407aa.js
@@ -437,7 +437,7 @@ window.search = window.search || {};
if (yes) {
loadSearchScript(
window.path_to_searchindex_js ||
- path_to_root + 'searchindex-339ac392.js',
+ path_to_root + 'searchindex-07c17d47.js',
'mdbook-search-index');
search_wrap.classList.remove('hidden');
searchicon.setAttribute('aria-expanded', 'true');
diff --git a/docs/searchindex-07c17d47.js b/docs/searchindex-07c17d47.js
new file mode 100644
index 000000000..2ae4c792b
--- /dev/null
+++ b/docs/searchindex-07c17d47.js
@@ -0,0 +1 @@
+window.search = Object.assign(window.search, JSON.parse('{"doc_urls":["welcome.html#welcome","welcome.html#target-audience","welcome.html#other-polkadot-contracts-resources","welcome.html#about","user_guide.html#resolc-user-guide","user_guide.html#revive-vs-resolc-nomenclature","user_guide/installation.html#installation","user_guide/installation.html#resolc-binary-releases","user_guide/installation.html#installing-the-solc-dependency","user_guide/installation.html#revive-npm-package","user_guide/installation.html#buidling-resolc-from-source","user_guide/cli.html#cli-usage","user_guide/cli.html#llvm-optimization-levels","user_guide/cli.html#newyork-ir-pipeline","user_guide/cli.html#stack-size","user_guide/cli.html#heap-size","user_guide/cli.html#solc","user_guide/cli.html#debug-artifacts","user_guide/cli.html#debug-info","user_guide/cli.html#deploy-time-linking","user_guide/js.html#js-npm-package","user_guide/tooling.html#tooling-integration","user_guide/tooling.html#solidity-toolkits","user_guide/tooling.html#compiler-explorer","user_guide/tooling.html#remix-ide","user_guide/std_json.html#standard-json-interface","user_guide/std_json.html#the-settingspolkavm-object","user_guide/std_json.html#settingspolkavmdebuginformation","user_guide/std_json.html#settingspolkavmnewyork","user_guide/std_json.html#the-settingspolkavmmemoryconfig-object","user_guide/std_json.html#the-settingsoptimizer-object","user_guide/std_json.html#settingsoptimizermode","user_guide/std_json.html#settingsllvmarguments","user_guide/std_json.html#the-settingsoutputselection-object","user_guide/std_json.html#the-all--wildcard","user_guide/std_json.html#the-contract-level-evm-output-selection","user_guide/differences.html#differences-to-evm","user_guide/differences.html#deploy-code-vs-runtime-code","user_guide/differences.html#solidity","user_guide/differences.html#the-6364-gas-rule","user_guide/differences.html#addresscreationcode","user_guide/differences.html#yul-functions","user_guide/differences.html#mload-mstore-msize-mcopy-memory-related-functions","user_guide/differences.html#calldataload-calldatacopy","user_guide/differences.html#codecopy","user_guide/differences.html#create-create2","user_guide/differences.html#dataoffset","user_guide/differences.html#datasize","user_guide/differences.html#revert-return","user_guide/differences.html#prevrandao-difficulty","user_guide/differences.html#pc-extcodecopy","user_guide/differences.html#blobhash-blobbasefee","user_guide/differences.html#difference-regarding-the-solc-via-ir-mode","user_guide/differences.html#example-state-variable-initialization-order-in-inheritance","user_guide/rust_libraries.html#rust-contract-libraries","revive_runner.html#revive-runner-sandbox","revive_runner.html#installation-and-usage","revive_runner.html#trace-logs","revive_runner.html#automatic-contract-instantiation","revive_runner.html#example","developer_guide.html#developer-guide","developer_guide/contributing.html#contributor-guide","developer_guide/contributing.html#getting-started","developer_guide/contributing.html#using-the-makefile","developer_guide/contributing.html#codebase-organization","developer_guide/contributing.html#contribution-rules","developer_guide/contributing.html#style-guide","developer_guide/contributing.html#ai-policy","developer_guide/architecture.html#compiler-architecture-and-internals","developer_guide/architecture.html#resolc","developer_guide/architecture.html#reproducible-contract-builds","developer_guide/architecture.html#the-revive-compiler-libraries","developer_guide/architecture.html#evm-heap-memory","developer_guide/architecture.html#the-llvm-dependency","developer_guide/architecture.html#custom-optimizations","developer_guide/newyork_optimizer.html#the-newyork-optimizer","developer_guide/newyork_optimizer.html#motivation","developer_guide/newyork_optimizer.html#pipeline-overview","developer_guide/newyork_optimizer.html#ir-design","developer_guide/newyork_optimizer.html#key-optimizations-explained","developer_guide/newyork_optimizer.html#type-narrowing","developer_guide/newyork_optimizer.html#guard-narrowing","developer_guide/newyork_optimizer.html#heap-optimization","developer_guide/newyork_optimizer.html#free-memory-pointer-range-proof","developer_guide/newyork_optimizer.html#soundness-traps-for-fmp-optimizations","developer_guide/newyork_optimizer.html#keccak256-fusion-and-folding","developer_guide/newyork_optimizer.html#compound-outlining-mapping-access","developer_guide/newyork_optimizer.html#fuzzy-function-deduplication","developer_guide/newyork_optimizer.html#revert-pattern-outlining","developer_guide/newyork_optimizer.html#outlined-helper-functions","developer_guide/newyork_optimizer.html#codesize-results","developer_guide/newyork_optimizer.html#integration-test-contracts","developer_guide/newyork_optimizer.html#openzeppelin-contracts","developer_guide/newyork_optimizer.html#development-history-and-challenges","developer_guide/newyork_optimizer.html#approaches-that-did-not-work","developer_guide/newyork_optimizer.html#known-limitations-and-future-work","developer_guide/newyork_optimizer.html#debug-output","developer_guide/newyork_optimizer.html#module-reference","developer_guide/newyork_ir.html#newyork-ir-reference","developer_guide/newyork_ir.html#how-to-read-this-reference","developer_guide/newyork_ir.html#entry-format","developer_guide/newyork_ir.html#syntax-notation","developer_guide/newyork_ir.html#operation-index","developer_guide/newyork_ir.html#type-system","developer_guide/newyork_ir.html#type","developer_guide/newyork_ir.html#bitwidth","developer_guide/newyork_ir.html#addressspace","developer_guide/newyork_ir.html#memoryregion","developer_guide/newyork_ir.html#pure-expressions-1","developer_guide/newyork_ir.html#0xhex","developer_guide/newyork_ir.html#vid","developer_guide/newyork_ir.html#add","developer_guide/newyork_ir.html#sub","developer_guide/newyork_ir.html#mul","developer_guide/newyork_ir.html#div","developer_guide/newyork_ir.html#sdiv","developer_guide/newyork_ir.html#mod","developer_guide/newyork_ir.html#smod","developer_guide/newyork_ir.html#exp","developer_guide/newyork_ir.html#and","developer_guide/newyork_ir.html#or","developer_guide/newyork_ir.html#xor","developer_guide/newyork_ir.html#shl","developer_guide/newyork_ir.html#shr","developer_guide/newyork_ir.html#sar","developer_guide/newyork_ir.html#lt","developer_guide/newyork_ir.html#gt","developer_guide/newyork_ir.html#slt","developer_guide/newyork_ir.html#sgt","developer_guide/newyork_ir.html#eq","developer_guide/newyork_ir.html#byte","developer_guide/newyork_ir.html#signextend","developer_guide/newyork_ir.html#addmod","developer_guide/newyork_ir.html#mulmod","developer_guide/newyork_ir.html#iszero","developer_guide/newyork_ir.html#not","developer_guide/newyork_ir.html#clz","developer_guide/newyork_ir.html#truncateibits","developer_guide/newyork_ir.html#zextibits","developer_guide/newyork_ir.html#sextibits","developer_guide/newyork_ir.html#keccak256","developer_guide/newyork_ir.html#keccak256_pair","developer_guide/newyork_ir.html#keccak256_single","developer_guide/newyork_ir.html#caller","developer_guide/newyork_ir.html#callvalue","developer_guide/newyork_ir.html#origin","developer_guide/newyork_ir.html#address","developer_guide/newyork_ir.html#chainid","developer_guide/newyork_ir.html#gas","developer_guide/newyork_ir.html#msize","developer_guide/newyork_ir.html#coinbase","developer_guide/newyork_ir.html#timestamp","developer_guide/newyork_ir.html#number","developer_guide/newyork_ir.html#difficulty","developer_guide/newyork_ir.html#gaslimit","developer_guide/newyork_ir.html#basefee","developer_guide/newyork_ir.html#blobbasefee","developer_guide/newyork_ir.html#blobhash","developer_guide/newyork_ir.html#blockhash","developer_guide/newyork_ir.html#selfbalance","developer_guide/newyork_ir.html#gasprice","developer_guide/newyork_ir.html#calldataload","developer_guide/newyork_ir.html#calldatasize","developer_guide/newyork_ir.html#returndatasize","developer_guide/newyork_ir.html#codesize","developer_guide/newyork_ir.html#extcodesize","developer_guide/newyork_ir.html#extcodehash","developer_guide/newyork_ir.html#balance","developer_guide/newyork_ir.html#mload","developer_guide/newyork_ir.html#sload","developer_guide/newyork_ir.html#tload","developer_guide/newyork_ir.html#mapping_sload","developer_guide/newyork_ir.html#dataoffset","developer_guide/newyork_ir.html#datasize","developer_guide/newyork_ir.html#loadimmutable","developer_guide/newyork_ir.html#linkersymbol","developer_guide/newyork_ir.html#func_name","developer_guide/newyork_ir.html#memory-and-storage-writes-1","developer_guide/newyork_ir.html#mstore","developer_guide/newyork_ir.html#mstore8","developer_guide/newyork_ir.html#mcopy","developer_guide/newyork_ir.html#sstore","developer_guide/newyork_ir.html#tstore","developer_guide/newyork_ir.html#mapping_sstore","developer_guide/newyork_ir.html#bulk-copies-1","developer_guide/newyork_ir.html#codecopy","developer_guide/newyork_ir.html#extcodecopy","developer_guide/newyork_ir.html#returndatacopy","developer_guide/newyork_ir.html#datacopy","developer_guide/newyork_ir.html#calldatacopy","developer_guide/newyork_ir.html#bindings-and-wrappers-1","developer_guide/newyork_ir.html#let","developer_guide/newyork_ir.html#expression-statement","developer_guide/newyork_ir.html#setimmutable","developer_guide/newyork_ir.html#structured-control-flow-1","developer_guide/newyork_ir.html#if","developer_guide/newyork_ir.html#switch","developer_guide/newyork_ir.html#for","developer_guide/newyork_ir.html#break","developer_guide/newyork_ir.html#continue","developer_guide/newyork_ir.html#leave","developer_guide/newyork_ir.html#nested-block","developer_guide/newyork_ir.html#external-interaction-1","developer_guide/newyork_ir.html#call","developer_guide/newyork_ir.html#callcode","developer_guide/newyork_ir.html#delegatecall","developer_guide/newyork_ir.html#staticcall","developer_guide/newyork_ir.html#create","developer_guide/newyork_ir.html#create2","developer_guide/newyork_ir.html#logn","developer_guide/newyork_ir.html#termination-1","developer_guide/newyork_ir.html#return","developer_guide/newyork_ir.html#revert","developer_guide/newyork_ir.html#stop","developer_guide/newyork_ir.html#invalid","developer_guide/newyork_ir.html#selfdestruct","developer_guide/newyork_ir.html#panic_revert","developer_guide/newyork_ir.html#error_string_revert","developer_guide/newyork_ir.html#custom_error_revert","developer_guide/target.html#pvm-and-the-pallet-revive-runtime-target","developer_guide/target.html#target-cpu-configuration","developer_guide/target.html#why-pvm","developer_guide/target.html#host-environment-pallet-revive","developer_guide/testing.html#testing-strategy","developer_guide/testing.html#bug-compatibility-with-ethereum-solidity","developer_guide/testing.html#differential-integration-tests","developer_guide/testing.html#the-differential-testing-utility","developer_guide/coverage.html#code-coverage","developer_guide/coverage.html#running-locally","developer_guide/coverage.html#reverting-local-changes","developer_guide/coverage.html#status","developer_guide/cross_compilation.html#cross-compilation","developer_guide/cross_compilation.html#wasm-via-emscripten","developer_guide/cross_compilation.html#musl-libc","faq.html#faq","faq.html#what-evm-version-do-you-support","faq.html#is-inline-assembly-supported","faq.html#do-you-support-opcode-xy","faq.html#in-what-solidity-version-should-i-write-my-dapp","faq.html#tool-xy-says-the-contract-size-is-larger-than-24kb-and-will-fail-to-deploy","faq.html#is-resolc-a-drop-in-replacement-for-solc","roadmap.html#vision-and-roadmap","roadmap.html#roadmap"],"index":{"documentStore":{"docInfo":{"0":{"body":74,"breadcrumbs":2,"title":1},"1":{"body":22,"breadcrumbs":3,"title":2},"10":{"body":6,"breadcrumbs":7,"title":3},"100":{"body":174,"breadcrumbs":8,"title":2},"101":{"body":235,"breadcrumbs":8,"title":2},"102":{"body":133,"breadcrumbs":8,"title":2},"103":{"body":25,"breadcrumbs":8,"title":2},"104":{"body":36,"breadcrumbs":7,"title":1},"105":{"body":91,"breadcrumbs":7,"title":1},"106":{"body":61,"breadcrumbs":7,"title":1},"107":{"body":80,"breadcrumbs":7,"title":1},"108":{"body":42,"breadcrumbs":8,"title":2},"109":{"body":78,"breadcrumbs":7,"title":1},"11":{"body":33,"breadcrumbs":8,"title":2},"110":{"body":56,"breadcrumbs":7,"title":1},"111":{"body":51,"breadcrumbs":7,"title":1},"112":{"body":47,"breadcrumbs":7,"title":1},"113":{"body":47,"breadcrumbs":7,"title":1},"114":{"body":49,"breadcrumbs":7,"title":1},"115":{"body":58,"breadcrumbs":7,"title":1},"116":{"body":40,"breadcrumbs":7,"title":1},"117":{"body":48,"breadcrumbs":7,"title":1},"118":{"body":51,"breadcrumbs":7,"title":1},"119":{"body":59,"breadcrumbs":6,"title":0},"12":{"body":59,"breadcrumbs":9,"title":3},"120":{"body":30,"breadcrumbs":6,"title":0},"121":{"body":31,"breadcrumbs":7,"title":1},"122":{"body":53,"breadcrumbs":7,"title":1},"123":{"body":65,"breadcrumbs":7,"title":1},"124":{"body":73,"breadcrumbs":7,"title":1},"125":{"body":41,"breadcrumbs":7,"title":1},"126":{"body":41,"breadcrumbs":7,"title":1},"127":{"body":40,"breadcrumbs":7,"title":1},"128":{"body":40,"breadcrumbs":7,"title":1},"129":{"body":38,"breadcrumbs":7,"title":1},"13":{"body":42,"breadcrumbs":9,"title":3},"130":{"body":59,"breadcrumbs":7,"title":1},"131":{"body":76,"breadcrumbs":7,"title":1},"132":{"body":57,"breadcrumbs":7,"title":1},"133":{"body":57,"breadcrumbs":7,"title":1},"134":{"body":33,"breadcrumbs":7,"title":1},"135":{"body":38,"breadcrumbs":6,"title":0},"136":{"body":61,"breadcrumbs":7,"title":1},"137":{"body":67,"breadcrumbs":7,"title":1},"138":{"body":45,"breadcrumbs":7,"title":1},"139":{"body":66,"breadcrumbs":7,"title":1},"14":{"body":62,"breadcrumbs":8,"title":2},"140":{"body":83,"breadcrumbs":7,"title":1},"141":{"body":68,"breadcrumbs":7,"title":1},"142":{"body":42,"breadcrumbs":7,"title":1},"143":{"body":24,"breadcrumbs":7,"title":1},"144":{"body":22,"breadcrumbs":7,"title":1},"145":{"body":25,"breadcrumbs":7,"title":1},"146":{"body":24,"breadcrumbs":7,"title":1},"147":{"body":22,"breadcrumbs":7,"title":1},"148":{"body":42,"breadcrumbs":7,"title":1},"149":{"body":54,"breadcrumbs":7,"title":1},"15":{"body":75,"breadcrumbs":8,"title":2},"150":{"body":23,"breadcrumbs":7,"title":1},"151":{"body":23,"breadcrumbs":7,"title":1},"152":{"body":21,"breadcrumbs":7,"title":1},"153":{"body":27,"breadcrumbs":7,"title":1},"154":{"body":21,"breadcrumbs":7,"title":1},"155":{"body":25,"breadcrumbs":7,"title":1},"156":{"body":26,"breadcrumbs":7,"title":1},"157":{"body":37,"breadcrumbs":7,"title":1},"158":{"body":42,"breadcrumbs":7,"title":1},"159":{"body":26,"breadcrumbs":7,"title":1},"16":{"body":10,"breadcrumbs":7,"title":1},"160":{"body":22,"breadcrumbs":7,"title":1},"161":{"body":40,"breadcrumbs":7,"title":1},"162":{"body":23,"breadcrumbs":7,"title":1},"163":{"body":42,"breadcrumbs":7,"title":1},"164":{"body":23,"breadcrumbs":7,"title":1},"165":{"body":41,"breadcrumbs":7,"title":1},"166":{"body":41,"breadcrumbs":7,"title":1},"167":{"body":42,"breadcrumbs":7,"title":1},"168":{"body":101,"breadcrumbs":7,"title":1},"169":{"body":84,"breadcrumbs":7,"title":1},"17":{"body":43,"breadcrumbs":8,"title":2},"170":{"body":49,"breadcrumbs":7,"title":1},"171":{"body":98,"breadcrumbs":7,"title":1},"172":{"body":54,"breadcrumbs":7,"title":1},"173":{"body":44,"breadcrumbs":7,"title":1},"174":{"body":47,"breadcrumbs":7,"title":1},"175":{"body":43,"breadcrumbs":7,"title":1},"176":{"body":134,"breadcrumbs":7,"title":1},"177":{"body":32,"breadcrumbs":9,"title":3},"178":{"body":110,"breadcrumbs":7,"title":1},"179":{"body":101,"breadcrumbs":7,"title":1},"18":{"body":15,"breadcrumbs":8,"title":2},"180":{"body":95,"breadcrumbs":7,"title":1},"181":{"body":107,"breadcrumbs":7,"title":1},"182":{"body":88,"breadcrumbs":7,"title":1},"183":{"body":112,"breadcrumbs":7,"title":1},"184":{"body":34,"breadcrumbs":8,"title":2},"185":{"body":63,"breadcrumbs":7,"title":1},"186":{"body":81,"breadcrumbs":7,"title":1},"187":{"body":80,"breadcrumbs":7,"title":1},"188":{"body":69,"breadcrumbs":7,"title":1},"189":{"body":63,"breadcrumbs":7,"title":1},"19":{"body":236,"breadcrumbs":9,"title":3},"190":{"body":25,"breadcrumbs":8,"title":2},"191":{"body":98,"breadcrumbs":6,"title":0},"192":{"body":80,"breadcrumbs":8,"title":2},"193":{"body":58,"breadcrumbs":7,"title":1},"194":{"body":35,"breadcrumbs":9,"title":3},"195":{"body":119,"breadcrumbs":6,"title":0},"196":{"body":107,"breadcrumbs":7,"title":1},"197":{"body":211,"breadcrumbs":6,"title":0},"198":{"body":47,"breadcrumbs":7,"title":1},"199":{"body":45,"breadcrumbs":7,"title":1},"2":{"body":7,"breadcrumbs":4,"title":3},"20":{"body":31,"breadcrumbs":9,"title":3},"200":{"body":73,"breadcrumbs":7,"title":1},"201":{"body":48,"breadcrumbs":8,"title":2},"202":{"body":20,"breadcrumbs":8,"title":2},"203":{"body":147,"breadcrumbs":7,"title":1},"204":{"body":68,"breadcrumbs":7,"title":1},"205":{"body":74,"breadcrumbs":7,"title":1},"206":{"body":70,"breadcrumbs":7,"title":1},"207":{"body":85,"breadcrumbs":7,"title":1},"208":{"body":61,"breadcrumbs":7,"title":1},"209":{"body":94,"breadcrumbs":7,"title":1},"21":{"body":9,"breadcrumbs":7,"title":2},"210":{"body":30,"breadcrumbs":7,"title":1},"211":{"body":62,"breadcrumbs":7,"title":1},"212":{"body":68,"breadcrumbs":7,"title":1},"213":{"body":28,"breadcrumbs":7,"title":1},"214":{"body":33,"breadcrumbs":7,"title":1},"215":{"body":55,"breadcrumbs":7,"title":1},"216":{"body":89,"breadcrumbs":7,"title":1},"217":{"body":100,"breadcrumbs":7,"title":1},"218":{"body":91,"breadcrumbs":7,"title":1},"219":{"body":9,"breadcrumbs":12,"title":5},"22":{"body":14,"breadcrumbs":7,"title":2},"220":{"body":14,"breadcrumbs":10,"title":3},"221":{"body":199,"breadcrumbs":8,"title":1},"222":{"body":34,"breadcrumbs":11,"title":4},"223":{"body":63,"breadcrumbs":6,"title":2},"224":{"body":34,"breadcrumbs":8,"title":4},"225":{"body":187,"breadcrumbs":7,"title":3},"226":{"body":73,"breadcrumbs":7,"title":3},"227":{"body":51,"breadcrumbs":6,"title":2},"228":{"body":79,"breadcrumbs":6,"title":2},"229":{"body":17,"breadcrumbs":7,"title":3},"23":{"body":11,"breadcrumbs":7,"title":2},"230":{"body":12,"breadcrumbs":5,"title":1},"231":{"body":19,"breadcrumbs":6,"title":2},"232":{"body":69,"breadcrumbs":7,"title":3},"233":{"body":12,"breadcrumbs":6,"title":2},"234":{"body":0,"breadcrumbs":2,"title":1},"235":{"body":12,"breadcrumbs":4,"title":3},"236":{"body":10,"breadcrumbs":4,"title":3},"237":{"body":4,"breadcrumbs":4,"title":3},"238":{"body":25,"breadcrumbs":5,"title":4},"239":{"body":13,"breadcrumbs":9,"title":8},"24":{"body":14,"breadcrumbs":7,"title":2},"240":{"body":9,"breadcrumbs":5,"title":4},"241":{"body":66,"breadcrumbs":4,"title":2},"242":{"body":49,"breadcrumbs":3,"title":1},"25":{"body":15,"breadcrumbs":9,"title":3},"26":{"body":6,"breadcrumbs":8,"title":2},"27":{"body":9,"breadcrumbs":7,"title":1},"28":{"body":31,"breadcrumbs":7,"title":1},"29":{"body":31,"breadcrumbs":8,"title":2},"3":{"body":15,"breadcrumbs":1,"title":0},"30":{"body":8,"breadcrumbs":8,"title":2},"31":{"body":10,"breadcrumbs":7,"title":1},"32":{"body":13,"breadcrumbs":7,"title":1},"33":{"body":4,"breadcrumbs":8,"title":2},"34":{"body":63,"breadcrumbs":7,"title":1},"35":{"body":83,"breadcrumbs":11,"title":5},"36":{"body":23,"breadcrumbs":7,"title":2},"37":{"body":41,"breadcrumbs":10,"title":5},"38":{"body":6,"breadcrumbs":6,"title":1},"39":{"body":18,"breadcrumbs":8,"title":3},"4":{"body":43,"breadcrumbs":6,"title":3},"40":{"body":5,"breadcrumbs":6,"title":1},"41":{"body":58,"breadcrumbs":7,"title":2},"42":{"body":64,"breadcrumbs":12,"title":7},"43":{"body":16,"breadcrumbs":7,"title":2},"44":{"body":3,"breadcrumbs":6,"title":1},"45":{"body":101,"breadcrumbs":7,"title":2},"46":{"body":3,"breadcrumbs":6,"title":1},"47":{"body":7,"breadcrumbs":6,"title":1},"48":{"body":8,"breadcrumbs":7,"title":2},"49":{"body":4,"breadcrumbs":7,"title":2},"5":{"body":52,"breadcrumbs":7,"title":4},"50":{"body":10,"breadcrumbs":7,"title":2},"51":{"body":20,"breadcrumbs":7,"title":2},"52":{"body":24,"breadcrumbs":11,"title":6},"53":{"body":57,"breadcrumbs":11,"title":6},"54":{"body":167,"breadcrumbs":9,"title":3},"55":{"body":36,"breadcrumbs":6,"title":3},"56":{"body":21,"breadcrumbs":5,"title":2},"57":{"body":38,"breadcrumbs":5,"title":2},"58":{"body":15,"breadcrumbs":6,"title":3},"59":{"body":120,"breadcrumbs":4,"title":1},"6":{"body":24,"breadcrumbs":5,"title":1},"60":{"body":11,"breadcrumbs":4,"title":2},"61":{"body":11,"breadcrumbs":6,"title":2},"62":{"body":8,"breadcrumbs":6,"title":2},"63":{"body":39,"breadcrumbs":6,"title":2},"64":{"body":85,"breadcrumbs":6,"title":2},"65":{"body":44,"breadcrumbs":6,"title":2},"66":{"body":107,"breadcrumbs":6,"title":2},"67":{"body":112,"breadcrumbs":6,"title":2},"68":{"body":58,"breadcrumbs":7,"title":3},"69":{"body":55,"breadcrumbs":5,"title":1},"7":{"body":21,"breadcrumbs":7,"title":3},"70":{"body":76,"breadcrumbs":7,"title":3},"71":{"body":65,"breadcrumbs":7,"title":3},"72":{"body":57,"breadcrumbs":7,"title":3},"73":{"body":69,"breadcrumbs":6,"title":2},"74":{"body":49,"breadcrumbs":6,"title":2},"75":{"body":44,"breadcrumbs":6,"title":2},"76":{"body":84,"breadcrumbs":5,"title":1},"77":{"body":372,"breadcrumbs":6,"title":2},"78":{"body":116,"breadcrumbs":6,"title":2},"79":{"body":0,"breadcrumbs":7,"title":3},"8":{"body":13,"breadcrumbs":7,"title":3},"80":{"body":182,"breadcrumbs":6,"title":2},"81":{"body":72,"breadcrumbs":6,"title":2},"82":{"body":118,"breadcrumbs":6,"title":2},"83":{"body":147,"breadcrumbs":9,"title":5},"84":{"body":349,"breadcrumbs":8,"title":4},"85":{"body":148,"breadcrumbs":7,"title":3},"86":{"body":43,"breadcrumbs":8,"title":4},"87":{"body":32,"breadcrumbs":7,"title":3},"88":{"body":56,"breadcrumbs":7,"title":3},"89":{"body":84,"breadcrumbs":7,"title":3},"9":{"body":5,"breadcrumbs":7,"title":3},"90":{"body":0,"breadcrumbs":6,"title":2},"91":{"body":67,"breadcrumbs":7,"title":3},"92":{"body":79,"breadcrumbs":6,"title":2},"93":{"body":216,"breadcrumbs":7,"title":3},"94":{"body":137,"breadcrumbs":6,"title":2},"95":{"body":137,"breadcrumbs":8,"title":4},"96":{"body":67,"breadcrumbs":6,"title":2},"97":{"body":139,"breadcrumbs":6,"title":2},"98":{"body":16,"breadcrumbs":9,"title":3},"99":{"body":74,"breadcrumbs":8,"title":2}},"docs":{"0":{"body":"Hello and a warm welcome to the revive Solidity compiler book! Warning Solidity on PVM is running on the pallet-revive runtime. This introduces observable semantic differences in comparison with the EVM. Study the differences section carefully. Ignoring these differences may lead to defunct contracts. Notable examples: The 63/64 gas rule isn’t implemented in the pallet (introduces potential DoS vector when calling other contracts) Contract instantiation works differently (by hash instead of by code) The gas model implemented by pallet-revive differs from Ethereum The heap size is fixed instead of gas-metered and there’s a fixed amount of stack size (contracts working fine on EVM may trap on PVM)","breadcrumbs":"Welcome » Welcome","id":"0","title":"Welcome"},"1":{"body":"Solidity dApp developers should read the user guide. Solidity on PolkaVM introduces important differences to EVM which should be well understood. Contributors will find the developer guide helpful for getting up to speed.","breadcrumbs":"Welcome » Target audience","id":"1","title":"Target audience"},"10":{"body":"Please follow the build instructions in the revive README.md.","breadcrumbs":"resolc user guide » Installation » Buidling resolc from source","id":"10","title":"Buidling resolc from source"},"100":{"body":"Each operation entry has the same shape: Field What it shows Heading The printed operation name (e.g. mstore) followed by the Expression or Statement variant it corresponds to in ir.rs. Description A short prose summary of what the operation does and any semantic notes worth knowing before reading the rest of the entry. Syntax The literal printer output, including any optional debug annotations (region tags, static-slot comments). Anything inside /* ... */ is a debug-only annotation and is not part of the operation itself. Example A minimal printed snippet, using the printer’s actual v0/ v1/… naming. Operands One row per input or structural participant in the printed syntax. Value operands list the narrowest type the operation guarantees (default i256; narrower widths only appear when type inference has narrowed an upstream definition). Vector-of-operands fields show Vec<…> as the type. Non-value participants such as nested regions are listed with an em-dash type to mark them as structural rather than as operands. Result and purity The type the operation produces (or none for statements that bind no value), followed by a purity label, either Pure or Effectful. Pure operations may be reordered, deduplicated, or eliminated by the simplifier; effectful ones may not. Effectful entries may carry a parenthetical describing the nature of the side effect when informative (e.g. “control flow”, “terminator”, or a note about revert/trap behavior). Annotations Operation-specific fields the printer surfaces as /* ... */ comments in the dump (region tag for memory ops, static-slot hint for storage ops, type suffix for non-default widths). Listed here as a table of source field → printed form.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Entry format","id":"100","title":"Entry format"},"101":{"body":"Syntax templates in each entry use the following conventions: Notation Meaning add, mload, if, else, case, let, yield, … Literal printer tokens: bare lowercase identifiers and keywords that the printer emits verbatim. $offset, $value, $key, $lhs, $rhs, … Role names ( $-prefixed): placeholders for SSA value references the printer renders as v followed by a decimal id ( v0, v1, …).
, , , , , , , , … Metavariables: stand for compile-time fields (type tags, hex values, identifier strings, integer counts), not SSA values. The concrete values they take are enumerated in the Annotations section of each entry or in the type system reference. […] Optional parts. Anything inside the brackets may or may not appear in any given dump, depending on the conditions described in the operation’s Annotations section. [: ] Optional type suffix on a value reference. Suppressed when the value’s type is the default i256 integer; present otherwise ( : i32, : ptr, …). /* … */ Debug-only annotations the printer attaches to certain operations (memory region tag, static-slot hint, etc.). … Repetition: “more entries of the same shape.” Used in vector operand lists ( $arg_0, $arg_1, …) and in multi-line block bodies ( { … }). For instance, this template: let $result[: ] := and($lhs[: ], $rhs[: ]) prints as: let v2: i8 := and(v0, v1: i8) $result rendered as v2 with an i8 type suffix, $lhs as v0 at the default i256 (type suffix omitted), and $rhs as v1 with an i8 type suffix. Note A value’s printed width is use-driven. Type inference assigns each value a forward width from its definition, then widens it to satisfy its uses. The type suffix shown for a value in an example (such as i8) is therefore only illustrative — a short example may not show the uses that determine it, and the same operation can appear with a wider suffix, or none (it is omitted for the default i256), in another program. For instance, a value used as a memory offset widens to i64; as an address (a call target, extcodesize) to i160; stored as a full word (an mstore/ sstore value) to i256; and an add/ mul operand up to the i64 register width.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Syntax notation","id":"101","title":"Syntax notation"},"102":{"body":"Pure expressions Constants and variables 0x v Arithmetic add sub mul div sdiv mod smod exp and or xor shl shr sar lt gt slt sgt eq byte signextend addmod mulmod iszero not clz Bit-width conversions truncate> zext> sext> Hashing keccak256 keccak256_pair keccak256_single Environment reads caller callvalue origin address chainid gas msize coinbase timestamp number difficulty gaslimit basefee blobbasefee blobhash blockhash selfbalance gasprice Calldata, returndata, and code calldataload calldatasize returndatasize codesize extcodesize extcodehash balance Memory and storage loads mload sload tload mapping_sload Linker dataoffset datasize loadimmutable linkersymbol Function call Memory and storage writes mstore mstore8 mcopy sstore tstore mapping_sstore Bulk copies codecopy extcodecopy returndatacopy datacopy calldatacopy Bindings and wrappers let expression statement setimmutable Structured control flow if switch for break continue leave nested block External interaction call callcode delegatecall staticcall create create2 log Termination return revert stop invalid selfdestruct panic_revert error_string_revert custom_error_revert","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Operation index","id":"102","title":"Operation index"},"103":{"body":"Every value in the IR carries a Type. The operation entries below refer to widths ( i1… i256), address spaces ( ptr, etc.), and memory regions ( scratch, etc.) by their printed form; this section is the reference for those names.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Type system","id":"103","title":"Type system"},"104":{"body":"The umbrella enum, with these variants: Variant Printed as Description Int(BitWidth) i1, i8, …, i256 An integer at one of the BitWidth widths. Ptr(AddressSpace) ptr, ptr, ptr, ptr A pointer tagged with its address space; see AddressSpace. Void void Unit type. Used for statements that produce no value and for void-returning functions.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Type","id":"104","title":"Type"},"105":{"body":"The rungs of integer width. Newly minted values default to I256; type inference narrows them down to one of the lower rungs when it can prove the upper bits are zero or unused. Variant Printed as Typical use I1 i1 Boolean. Result type of every comparison and iszero. I8 i8 Byte values. The narrowest meaningful integer. I32 i32 PolkaVM pointer width (XLEN); minimum width for function parameters under the rv64e ABI. I64 i64 PolkaVM native register width; most narrowed values land here. I128 i128 Two registers; arithmetic that overflows i64 but doesn’t need full 256-bit emulation. I160 i160 Ethereum addresses; result of caller, origin, mapping keys. I256 i256 EVM word width. The default and conservative ceiling.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » BitWidth","id":"105","title":"BitWidth"},"106":{"body":"The address space a pointer points into. Carried on every Ptr value so the codegen can lower loads and stores without a separate alias-analysis pass. Variant Printed as Points into Endianness Heap ptr Emulated EVM linear memory (the simulated mload/ mstore region). Big-endian (by EVM contract). Stack ptr Native PolkaVM stack allocations. Little-endian (no swap). Storage ptr Contract storage; key/value with 256-bit slots. Big-endian on the wire. Code ptr Read-only code/data segment. Big-endian.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » AddressSpace","id":"106","title":"AddressSpace"},"107":{"body":"A refinement carried by every memory load and store on top of AddressSpace::Heap. The tag tells later passes what kind of heap address an offset is hitting, which drives both free-memory-pointer propagation and byte-swap elimination. Variant Address range Printed as Meaning Scratch 0x00– 0x3f /* scratch */ EVM scratch space; safe to touch without consulting the free memory pointer. FreePointerSlot exactly 0x40 /* free_ptr */ Slot that stores the free memory pointer itself. Dynamic 0x80 and above /* dynamic */ Real heap allocations. Unknown everything else (constants in 0x41– 0x7f, plus all non-constant offsets) (suppressed) Conservative fallback used when the offset isn’t a constant or doesn’t slot cleanly.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » MemoryRegion","id":"107","title":"MemoryRegion"},"108":{"body":"Pure expressions produce values without side effects. The simplifier may freely reorder, deduplicate, and eliminate them. They appear on the right-hand side of a let binding, or as operands of other expressions and effectful statements; the operand positions accept SSA value references only, so any pure expression that is consumed elsewhere is first bound by a let. Examples in this section wrap each expression in a let v := … to give it somewhere to land.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Pure expressions","id":"108","title":"Pure expressions"},"109":{"body":"( Expression::Literal) Description A compile-time constant value with a declared type. New literals minted by the translator default to Int(I256); passes that synthesize constants at narrower widths (e.g. a one-bit boolean from a constant comparison) attach the narrower type directly. Syntax 0x[: ] Example let v0: i8 := 0x2a\\nlet v1: i1 := 0x1 // boolean true\\nlet v2: i64 := 0x80 Operands None — literals are leaves. Result and purity Result Purity Same as the literal’s value_type Pure Annotations Source field Printed as value: BigUint 0x in the syntax position (not a comment annotation; it is the expression itself) value_type: Type : suffix when value_type is not the default Int(I256); suppressed otherwise","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » 0x","id":"109","title":"0x"},"11":{"body":"We aim to keep the resolc CLI usage close to solc. There are a few things and options worthwhile to know about in resolc which do not exist in the Ethereum world. This chapter explains those in more detail than the CLI help message. Tip For the complete help about CLI options, please see resolc --help.","breadcrumbs":"resolc user guide » Command Line Interface » CLI usage","id":"11","title":"CLI usage"},"110":{"body":"( Expression::Var) Description A reference to an existing SSA value, used as the entire right-hand side of a let. In a typical dump this is rare because the simplifier collapses let v := v into the consumers of v via copy propagation; expect to see it only in dumps taken before simplification has run. Syntax v Example let v5 := v3 // copy; usually eliminated by simplify Operands None — the expression is the value reference itself. Result and purity Result Purity Same as the referenced value’s type Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » v","id":"110","title":"v"},"111":{"body":"( Expression::Binary with BinaryOperation::Add) Description Modular addition. Wraps on overflow; per EVM, the result is (lhs + rhs) mod 2^N where N is the operand width. Syntax add($lhs[: ], $rhs[: ]) Example let v2 := add(v0, v1) Operands Name Type Notes lhs i256 — rhs i256 — Result and purity Result Purity widen_by_one(max(width(lhs), width(rhs))) — one tier above the wider operand to account for the carry bit Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » add","id":"111","title":"add"},"112":{"body":"( Expression::Binary with BinaryOperation::Sub) Description Modular subtraction. Wraps on underflow; the result is (lhs - rhs) mod 2^256 regardless of operand widths. Syntax sub($lhs[: ], $rhs[: ]) Example let v2 := sub(v0, v1) Operands Name Type Notes lhs i256 — rhs i256 — Result and purity Result Purity i256 — conservative; underflow on narrower operands could borrow into upper bits Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » sub","id":"112","title":"sub"},"113":{"body":"( Expression::Binary with BinaryOperation::Mul) Description Modular multiplication. The result is (lhs * rhs) mod 2^256. Syntax mul($lhs[: ], $rhs[: ]) Example let v2 := mul(v0, v1) Operands Name Type Notes lhs i256 — rhs i256 — Result and purity Result Purity double_width(max(width(lhs), width(rhs))) — the tier holding twice the wider operand’s bits (skipping i160 at the i128 → i256 transition) Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mul","id":"113","title":"mul"},"114":{"body":"( Expression::Binary with BinaryOperation::Div) Description Unsigned integer division. Per EVM, div(x, 0) = 0 (no trap on division by zero). Syntax div($lhs[: ], $rhs[: ]) Example let v2 := div(v0, v1) Operands Name Type Notes lhs i256 Dividend. rhs i256 Divisor; 0 yields a result of 0, not a trap. Result and purity Result Purity width(lhs) — the quotient cannot exceed the dividend Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » div","id":"114","title":"div"},"115":{"body":"( Expression::Binary with BinaryOperation::SDiv) Description Signed two’s-complement integer division. Per EVM, sdiv(x, 0) = 0; quotient is truncated toward zero. Syntax sdiv($lhs[: ], $rhs[: ]) Example let v2 := sdiv(v0, v1) Operands Name Type Notes lhs i256 Dividend, treated as signed. rhs i256 Divisor, treated as signed; 0 yields 0. Result and purity Result Purity max(width(lhs), width(rhs)) — a negative divisor can push the result to full width Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » sdiv","id":"115","title":"sdiv"},"116":{"body":"( Expression::Binary with BinaryOperation::Mod) Description Unsigned modulo. Per EVM, mod(x, 0) = 0. Syntax mod($lhs[: ], $rhs[: ]) Example let v2 := mod(v0, v1) Operands Name Type Notes lhs i256 Dividend. rhs i256 Divisor; 0 yields 0. Result and purity Result Purity width(lhs) Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mod","id":"116","title":"mod"},"117":{"body":"( Expression::Binary with BinaryOperation::SMod) Description Signed modulo. Per EVM, smod(x, 0) = 0; the result takes the sign of the dividend. Syntax smod($lhs[: ], $rhs[: ]) Example let v2 := smod(v0, v1) Operands Name Type Notes lhs i256 Dividend, treated as signed. rhs i256 Divisor, treated as signed; 0 yields 0. Result and purity Result Purity width(lhs) Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » smod","id":"117","title":"smod"},"118":{"body":"( Expression::Binary with BinaryOperation::Exp) Description Modular exponentiation: (base ^ exponent) mod 2^256. The most expensive arithmetic opcode in EVM (variable gas cost proportional to the byte length of exponent). Syntax exp($base[: ], $exponent[: ]) Example let v2 := exp(v0, v1) Operands Name Type Notes base i256 Base. exponent i256 Exponent. Result and purity Result Purity i256 — conservative; exponentiation can fill any width Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » exp","id":"118","title":"exp"},"119":{"body":"( Expression::Binary with BinaryOperation::And) Description Bitwise AND. The common idiom for type narrowing: a constant mask on the right lets forward analysis pick up a tight result width. Syntax and($lhs[: ], $rhs[: ]) Example let v2 := and(v0, v1)\\nlet v3: i8 := 0xff\\nlet v4: i8 := and(v0, v3: i8) Operands Name Type Notes lhs i256 — rhs i256 — Result and purity Result Purity min(width(lhs), width(rhs)) — AND can only clear bits, so the result fits in the narrower operand Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » and","id":"119","title":"and"},"12":{"body":"-O, --optimization resolc exposes the optimization level setting for the LLVM backend. The performance and size of compiled contracts varies widely between different optimization levels. (This is independent of --newyork which selects the IR lowering pipeline.) Valid levels are the following: 0: No optimizations are applied. 1: Basic optimizations for execution time. 2: Advanced optimizations for execution time. 3: Aggressive optimizations for execution time. s: Optimize for code size. z: Aggressively optimize for code size. By default, -Oz is applied.","breadcrumbs":"resolc user guide » Command Line Interface » LLVM optimization levels","id":"12","title":"LLVM optimization levels"},"120":{"body":"( Expression::Binary with BinaryOperation::Or) Description Bitwise OR. Syntax or($lhs[: ], $rhs[: ]) Example let v2 := or(v0, v1) Operands Name Type Notes lhs i256 — rhs i256 — Result and purity Result Purity max(width(lhs), width(rhs)) Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » or","id":"120","title":"or"},"121":{"body":"( Expression::Binary with BinaryOperation::Xor) Description Bitwise XOR. Syntax xor($lhs[: ], $rhs[: ]) Example let v2 := xor(v0, v1) Operands Name Type Notes lhs i256 — rhs i256 — Result and purity Result Purity max(width(lhs), width(rhs)) Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » xor","id":"121","title":"xor"},"122":{"body":"( Expression::Binary with BinaryOperation::Shl) Description Logical left shift. Operand order follows EVM: shl(shift, value) computes value << shift. Shifts ≥ 256 produce 0. Syntax shl($shift[: ], $value[: ]) Example let v2 := shl(v0, v1) Operands Name Type Notes shift i256 Shift amount in bits. value i256 Value to shift. Result and purity Result Purity i256 — conservative; bits may shift into any width Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » shl","id":"122","title":"shl"},"123":{"body":"( Expression::Binary with BinaryOperation::Shr) Description Logical right shift. Operand order follows EVM: shr(shift, value) computes value >> shift with zero-fill from the left. Shifts ≥ 256 produce 0. Syntax shr($shift[: ], $value[: ]) Example let v2 := shr(v0, v1) Operands Name Type Notes shift i256 Shift amount in bits. value i256 Value to shift. Result and purity Result Purity If shift is a known constant k: tier holding 256 - k bits (or i1 for k ≥ 256). Otherwise: width(value). Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » shr","id":"123","title":"shr"},"124":{"body":"( Expression::Binary with BinaryOperation::Sar) Description Arithmetic (signed) right shift. Operand order follows EVM: sar(shift, value) shifts value right by shift bits, preserving the sign bit. Shifts ≥ 256 saturate to 0 for non-negative values and to -1 (all-ones) for negative values. Syntax sar($shift[: ], $value[: ]) Example let v2 := sar(v0, v1) Operands Name Type Notes shift i256 Shift amount in bits. value i256 Value to shift, treated as signed. Result and purity Result Purity width(value) — unlike shr, sign-extension means a constant shift cannot narrow the result Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » sar","id":"124","title":"sar"},"125":{"body":"( Expression::Binary with BinaryOperation::Lt) Description Unsigned less-than comparison. Returns 1 if lhs < rhs, else 0. Syntax lt($lhs[: ], $rhs[: ]) Example let v2: i1 := lt(v0, v1) Operands Name Type Notes lhs i256 Compared unsigned. rhs i256 Compared unsigned. Result and purity Result Purity i1 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » lt","id":"125","title":"lt"},"126":{"body":"( Expression::Binary with BinaryOperation::Gt) Description Unsigned greater-than comparison. Returns 1 if lhs > rhs, else 0. Syntax gt($lhs[: ], $rhs[: ]) Example let v2: i1 := gt(v0, v1) Operands Name Type Notes lhs i256 Compared unsigned. rhs i256 Compared unsigned. Result and purity Result Purity i1 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » gt","id":"126","title":"gt"},"127":{"body":"( Expression::Binary with BinaryOperation::Slt) Description Signed less-than comparison. Operands are treated as two’s complement. Syntax slt($lhs[: ], $rhs[: ]) Example let v2: i1 := slt(v0, v1) Operands Name Type Notes lhs i256 Compared signed. rhs i256 Compared signed. Result and purity Result Purity i1 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » slt","id":"127","title":"slt"},"128":{"body":"( Expression::Binary with BinaryOperation::Sgt) Description Signed greater-than comparison. Operands are treated as two’s complement. Syntax sgt($lhs[: ], $rhs[: ]) Example let v2: i1 := sgt(v0, v1) Operands Name Type Notes lhs i256 Compared signed. rhs i256 Compared signed. Result and purity Result Purity i1 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » sgt","id":"128","title":"sgt"},"129":{"body":"( Expression::Binary with BinaryOperation::Eq) Description Equality comparison. Returns 1 if lhs == rhs, else 0. Signedness is irrelevant. Syntax eq($lhs[: ], $rhs[: ]) Example let v2: i1 := eq(v0, v1) Operands Name Type Notes lhs i256 — rhs i256 — Result and purity Result Purity i1 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » eq","id":"129","title":"eq"},"13":{"body":"--newyork Enables the newyork optimizer to reduced compiled contract code size, by routing Yul lowering through the experimental newyork IR pipeline instead of the standard Yul-to-LLVM path. Composes with --yul, --combined-json, and the default Solidity mode. In standard JSON mode this flag is rejected; enable the pipeline via the settings.polkavm.newyork input field instead. Off by default.","breadcrumbs":"resolc user guide » Command Line Interface » newyork IR pipeline","id":"13","title":"newyork IR pipeline"},"130":{"body":"( Expression::Binary with BinaryOperation::Byte) Description Extract a single byte from a 256-bit word. byte(i, x) returns the i-th byte of x with byte 0 being the most significant. If i ≥ 32, the result is 0. Syntax byte($index[: ], $word[: ]) Example let v2: i8 := byte(v0, v1) Operands Name Type Notes index i256 Byte position; 0 = most significant byte. Values ≥ 32 yield 0. word i256 Source word. Result and purity Result Purity i8 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » byte","id":"130","title":"byte"},"131":{"body":"( Expression::Binary with BinaryOperation::SignExtend) Description Sign-extend an integer from a byte position. Per EVM, signextend(b, x) treats byte b of x as the most significant byte of a smaller signed integer and extends its sign through the upper bytes. Syntax signextend($byte_position[: ], $value[: ]) Example let v2 := signextend(v0, v1) Operands Name Type Notes byte_position i256 Byte position of the sign byte (0–31). value i256 Source value. Result and purity Result Purity i256 — the extended value occupies the full word Pure Annotations The width-targeted sign-extension primitive sext> ( Expression::SignExtendTo) is a separate operation; see the bit-width conversions section.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » signextend","id":"131","title":"signextend"},"132":{"body":"( Expression::Ternary with BinaryOperation::AddMod) Description Ternary modular addition: (a + b) mod n, computed without intermediate overflow. Per EVM, n = 0 yields 0. Syntax addmod($a[: ], $b[: ], $n[: ]) Example let v3 := addmod(v0, v1, v2) Operands Name Type Notes a i256 First addend. b i256 Second addend. n i256 Modulus; 0 yields 0. Result and purity Result Purity i256 — conservative Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » addmod","id":"132","title":"addmod"},"133":{"body":"( Expression::Ternary with BinaryOperation::MulMod) Description Ternary modular multiplication: (a * b) mod n, computed without intermediate overflow. Per EVM, n = 0 yields 0. Syntax mulmod($a[: ], $b[: ], $n[: ]) Example let v3 := mulmod(v0, v1, v2) Operands Name Type Notes a i256 First factor. b i256 Second factor. n i256 Modulus; 0 yields 0. Result and purity Result Purity i256 — conservative Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mulmod","id":"133","title":"mulmod"},"134":{"body":"( Expression::Unary with UnaryOperation::IsZero) Description Returns 1 if the operand is 0, else 0. Also serves as the logical NOT for boolean values. Syntax iszero($operand[: ]) Example let v1: i1 := iszero(v0) Operands Name Type Notes operand i256 — Result and purity Result Purity i1 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » iszero","id":"134","title":"iszero"},"135":{"body":"( Expression::Unary with UnaryOperation::Not) Description Bitwise complement. Inverts every bit; equivalent to xor(operand, 2^256 - 1). Syntax not($operand[: ]) Example let v1 := not(v0) Operands Name Type Notes operand i256 — Result and purity Result Purity i256 — the complement fills the full word regardless of operand width Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » not","id":"135","title":"not"},"136":{"body":"( Expression::Unary with UnaryOperation::Clz) Description Count leading zeros. Returns the number of leading zero bits in the operand, where a value of 0 returns 256 (the full width). Not an EVM opcode; reaches newyork as a Yul builtin ( FunctionName::Clz) and is translated directly by the Yul-to-newyork translator. Syntax clz($operand[: ]) Example let v1 := clz(v0) Operands Name Type Notes operand i256 — Result and purity Result Purity i256 — in practice the value fits in nine bits (max 256), so type inference often narrows further Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » clz","id":"136","title":"clz"},"137":{"body":"( Expression::Truncate) Description Reinterpret a wider integer as a narrower one by discarding the upper bits. The destination width is carried in the IR’s to: BitWidth field and is rendered inside the angle brackets of the printer mnemonic. Narrowing-only; the source width must be greater than or equal to the destination width. Syntax truncate>($value[: ]) Example let v1: i64 := truncate(v0)\\nlet v2: i8 := truncate(v1: i64) Operands Name Type Notes value i256 Source value; must be at least as wide as the destination. Result and purity Result Purity The destination width from the to field Pure Annotations None. The destination width is part of the operation name, not a debug annotation.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » truncate>","id":"137","title":"truncate>"},"138":{"body":"( Expression::ZeroExtend) Description Reinterpret a narrower integer as a wider one by zero-filling the upper bits. The destination width is carried in the IR’s to: BitWidth field. Widening-only. Syntax zext>($value[: ]) Example let v1 := zext(v0: i8) Operands Name Type Notes value i256 Source value; must be no wider than the destination. Result and purity Result Purity The destination width from the to field Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » zext>","id":"138","title":"zext>"},"139":{"body":"( Expression::SignExtendTo) Description Reinterpret a narrower signed integer as a wider one by sign-extending the high bit. The destination width is carried in the IR’s to: BitWidth field. Distinct from signextend ( Expression::Binary), which is the EVM byte-position primitive; this one specifies the destination width directly and is introduced by passes that produce a sign-extended value at a known target width. Syntax sext>($value[: ]) Example let v1 := sext(v0: i64) Operands Name Type Notes value i256 Source value; must be no wider than the destination. Result and purity Result Purity The destination width from the to field Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » sext>","id":"139","title":"sext>"},"14":{"body":"--stack-size PVM is a register machine with a traditional stack memory space for local variables. This controls the total amount of stack space the contract can use. You are incentivized to keep this value as small as possible: Increasing the stack size will increase gas costs due to increased startup costs. The stack size contributes to the total memory size a contract can use, which includes the contract’s code size. Default value: 131072 Warning If the contract uses more stack memory than configured, it will compile fine but eventually revert execution at runtime!","breadcrumbs":"resolc user guide » Command Line Interface » Stack size","id":"14","title":"Stack size"},"140":{"body":"( Expression::Keccak256) Description Compute the Keccak-256 hash of length bytes of emulated EVM linear memory starting at offset. The general-purpose hashing primitive; the specialized variants below cover the common scratch-space patterns more compactly. Syntax keccak256($offset[: ], $length[: ]) Example let v2 := keccak256(v0, v1) Operands Name Type Notes offset i256 Byte offset into linear memory; forward analysis widens to at least i64. length i256 Length of the region to hash, in bytes; forward analysis widens to at least i64. Result and purity Result Purity i256 Pure — the hash is a deterministic function of the memory contents at evaluation time. Passes that hoist or dedupe must respect intervening memory writes. Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » keccak256","id":"140","title":"keccak256"},"141":{"body":"( Expression::Keccak256Pair) Description Compound hash of two 256-bit words. Equivalent to mstore(0, word0); mstore(32, word1); keccak256(0, 64) but emitted as a single outlined call after mem_opt’s keccak fusion recognizes the pattern. The mapping-key idiom; see also mapping_sload. Syntax keccak256_pair($word0[: ], $word1[: ]) Example let v2 := keccak256_pair(v0, v1) Operands Name Type Notes word0 i256 First word; the high 32 bytes of the hash input. word1 i256 Second word; the low 32 bytes of the hash input. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » keccak256_pair","id":"141","title":"keccak256_pair"},"142":{"body":"( Expression::Keccak256Single) Description Compound hash of a single 256-bit word. Equivalent to mstore(0, word0); keccak256(0, 32) but emitted as a single outlined call after mem_opt’s keccak fusion. Syntax keccak256_single($word0[: ]) Example let v1 := keccak256_single(v0) Operands Name Type Notes word0 i256 The word to hash. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » keccak256_single","id":"142","title":"keccak256_single"},"143":{"body":"( Expression::Caller) Description Address of the immediate caller of the current call frame. Syntax caller() Example let v0: i160 := caller() Operands None. Result and purity Result Purity i160 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » caller","id":"143","title":"caller"},"144":{"body":"( Expression::CallValue) Description Value (wei) attached to the current call. Syntax callvalue() Example let v0 := callvalue() Operands None. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » callvalue","id":"144","title":"callvalue"},"145":{"body":"( Expression::Origin) Description Address of the original externally owned account that initiated the transaction. Syntax origin() Example let v0: i160 := origin() Operands None. Result and purity Result Purity i160 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » origin","id":"145","title":"origin"},"146":{"body":"( Expression::Address) Description Address of the contract executing the current call frame. Syntax address() Example let v0: i160 := address() Operands None. Result and purity Result Purity i160 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » address","id":"146","title":"address"},"147":{"body":"( Expression::ChainId) Description Chain identifier of the network the contract is executing on. Syntax chainid() Example let v0 := chainid() Operands None. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » chainid","id":"147","title":"chainid"},"148":{"body":"( Expression::Gas) Description Remaining gas at the point of evaluation. Modeled as a pure expression for IR purposes; in practice it changes between evaluations, so any simplifier that deduplicates pure expressions must respect gas as a barrier. Syntax gas() Example let v0: i64 := gas() Operands None. Result and purity Result Purity i64 Pure (per IR; see Description) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » gas","id":"148","title":"gas"},"149":{"body":"( Expression::MSize) Description Highest byte offset of emulated EVM linear memory that has been touched, rounded up to the next 32-byte boundary. Unlike gas, classified as side-effectful by the simplifier: unused msize() bindings are not eliminated, because the result depends on the program’s memory-access history and would change if the surrounding statements were reordered. Syntax msize() Example let v0: i64 := msize() Operands None. Result and purity Result Purity i64 Effectful (see Description) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » msize","id":"149","title":"msize"},"15":{"body":"--heap-size Unlike the EVM, due to the lack of dynamic memory metering, PVM contracts emulate the EVM heap memory with a static buffer. Consequentially, instead of infinite memory with exponentially growing gas costs, PVM contracts have a finite amount of memory with constant gas costs available. You are incentivized to keep this value as small as possible:\\n1.Increasing the heap size will increase startup costs.\\n2.The heap size contributes to the total memory size a contract can use, which includes the contract’s code size Default value: 131072 Warning If the contract uses more heap memory than configured, it will compile fine but eventually revert execution at runtime!","breadcrumbs":"resolc user guide » Command Line Interface » Heap size","id":"15","title":"Heap size"},"150":{"body":"( Expression::Coinbase) Description Address of the block’s coinbase (block author). Syntax coinbase() Example let v0: i160 := coinbase() Operands None. Result and purity Result Purity i160 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » coinbase","id":"150","title":"coinbase"},"151":{"body":"( Expression::Timestamp) Description Block timestamp, as a Unix epoch second. Syntax timestamp() Example let v0: i64 := timestamp() Operands None. Result and purity Result Purity i64 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » timestamp","id":"151","title":"timestamp"},"152":{"body":"( Expression::Number) Description Current block number. Syntax number() Example let v0: i64 := number() Operands None. Result and purity Result Purity i64 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » number","id":"152","title":"number"},"153":{"body":"( Expression::Difficulty) Description Pre-merge block difficulty. On post-merge chains this is the block’s prevrandao value. Syntax difficulty() Example let v0 := difficulty() Operands None. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » difficulty","id":"153","title":"difficulty"},"154":{"body":"( Expression::GasLimit) Description Block gas limit. Syntax gaslimit() Example let v0: i64 := gaslimit() Operands None. Result and purity Result Purity i64 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » gaslimit","id":"154","title":"gaslimit"},"155":{"body":"( Expression::BaseFee) Description Current block’s EIP-1559 base fee per gas. Syntax basefee() Example let v0 := basefee() Operands None. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » basefee","id":"155","title":"basefee"},"156":{"body":"( Expression::BlobBaseFee) Description Current block’s EIP-4844 blob base fee per gas. Syntax blobbasefee() Example let v0 := blobbasefee() Operands None. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » blobbasefee","id":"156","title":"blobbasefee"},"157":{"body":"( Expression::BlobHash) Description Versioned hash of the blob at the given index in the current transaction’s blob list. Syntax blobhash($index[: ]) Example let v1 := blobhash(v0) Operands Name Type Notes index i256 Blob index; forward analysis widens to at least i64. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » blobhash","id":"157","title":"blobhash"},"158":{"body":"( Expression::BlockHash) Description Hash of the block with the given number. Per EVM, valid only for the most recent 256 blocks; outside that range the result is 0. Syntax blockhash($number[: ]) Example let v1 := blockhash(v0) Operands Name Type Notes number i256 Block number; forward analysis widens to i256. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » blockhash","id":"158","title":"blockhash"},"159":{"body":"( Expression::SelfBalance) Description Balance (in wei) of the contract executing the current call frame. Cheaper than balance(address()). Syntax selfbalance() Example let v0 := selfbalance() Operands None. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » selfbalance","id":"159","title":"selfbalance"},"16":{"body":"--solc Specify the path to the solc executable. By default, the one in ${PATH} is used.","breadcrumbs":"resolc user guide » Command Line Interface » solc","id":"16","title":"solc"},"160":{"body":"( Expression::GasPrice) Description Effective gas price of the current transaction. Syntax gasprice() Example let v0 := gasprice() Operands None. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » gasprice","id":"160","title":"gasprice"},"161":{"body":"( Expression::CallDataLoad) Description Read 32 bytes from the current call’s calldata at the given offset. Reads past the end of calldata return zero bytes. Syntax calldataload($offset[: ]) Example let v1 := calldataload(v0) Operands Name Type Notes offset i256 Byte offset into calldata. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » calldataload","id":"161","title":"calldataload"},"162":{"body":"( Expression::CallDataSize) Description Length of the current call’s calldata, in bytes. Syntax calldatasize() Example let v0: i64 := calldatasize() Operands None. Result and purity Result Purity i64 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » calldatasize","id":"162","title":"calldatasize"},"163":{"body":"( Expression::ReturnDataSize) Description Length of the most recently returned data buffer from a sub-call, in bytes. Modeled as pure per IR but reflects the last ExternalCall / Create result; consumers must respect that ordering. Syntax returndatasize() Example let v0: i64 := returndatasize() Operands None. Result and purity Result Purity i64 Pure (per IR; see Description) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » returndatasize","id":"163","title":"returndatasize"},"164":{"body":"( Expression::CodeSize) Description Size of the currently executing code, in bytes. Syntax codesize() Example let v0: i64 := codesize() Operands None. Result and purity Result Purity i64 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » codesize","id":"164","title":"codesize"},"165":{"body":"( Expression::ExtCodeSize) Description Size of the code deployed at the given address, in bytes. Returns 0 for accounts with no deployed code. Syntax extcodesize($address[: ]) Example let v1: i64 := extcodesize(v0: i160) Operands Name Type Notes address i256 Account address; forward analysis widens to at least i160. Result and purity Result Purity i64 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » extcodesize","id":"165","title":"extcodesize"},"166":{"body":"( Expression::ExtCodeHash) Description Keccak-256 hash of the code deployed at the given address. Returns 0 for non-existent accounts. Syntax extcodehash($address[: ]) Example let v1 := extcodehash(v0: i160) Operands Name Type Notes address i256 Account address; forward analysis widens to at least i160. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » extcodehash","id":"166","title":"extcodehash"},"167":{"body":"( Expression::Balance) Description Balance (in wei) of the given account address. Use selfbalance for the contract executing the current call frame (cheaper). Syntax balance($address[: ]) Example let v1 := balance(v0: i160) Operands Name Type Notes address i256 Account address; forward analysis widens to at least i160. Result and purity Result Purity i256 Pure Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » balance","id":"167","title":"balance"},"168":{"body":"( Expression::MLoad) Description Read a 32-byte word from emulated EVM linear memory at offset. The word is read big-endian per EVM semantics. Pure per IR, but reads after writes return the new value; the memory passes track read/write dependencies separately. Syntax mload($offset[: ]) [/* */] Example let v1 := mload(v0: i64)\\nlet v2: i32 := mload(v3: i64) /* free_ptr */ Operands Name Type Notes offset i256 Byte offset into linear memory; forward analysis widens to at least i64. Result and purity Result Purity i32 when region is FreePointerSlot; i256 otherwise Pure (per IR; see Description) Annotations Source field Printed as region: MemoryRegion /* scratch */ · /* free_ptr */ · /* dynamic */ ( Unknown is suppressed) Same tagging rules as mstore. The region also determines the result width: a load from FreePointerSlot produces an i32 since the FMP fits in a pointer-sized word.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mload","id":"168","title":"mload"},"169":{"body":"( Expression::SLoad) Description Read a 32-byte word from persistent contract storage at the given key. Pure per IR; reads after writes to the same slot return the new value. Syntax sload($key[: ]) [/* slot: 0x */] Example let v1 := sload(v0)\\nlet v2 := sload(v3) /* slot: 0x0 */ Operands Name Type Notes key i256 Storage slot. Result and purity Result Purity i256 Pure (per IR; see Description) Annotations Source field Printed as static_slot: Option /* slot: 0x */ when set; suppressed otherwise Same tagging rules as sstore. The printer renders the annotation whenever the field is Some and the deduplicator’s canonicalizer partitions signatures by slot; no pass currently writes Some(...), however, so in present-day dumps the annotation is dormant.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » sload","id":"169","title":"sload"},"17":{"body":"--debug-output-dir Dump all intermediary compiler artifacts to files in the specified directory. This includes the Yul IR, optimized and unoptimized LLVM IR, the ELF object and the PVM assembly. When the newyork pipeline is active, the newyork IR is additionally dumped (the final IR, a pre-late-pass snapshot, and heap and memory optimization data). Useful for debugging and development purposes.","breadcrumbs":"resolc user guide » Command Line Interface » Debug artifacts","id":"17","title":"Debug artifacts"},"170":{"body":"( Expression::TLoad) Description Read a 32-byte word from transient storage at the given key. Transient storage is wiped at the end of the transaction; pair with tstore. Syntax tload($key[: ]) Example let v1 := tload(v0) Operands Name Type Notes key i256 Transient storage slot. Result and purity Result Purity i256 Pure (per IR; see Description) Annotations None. The IR does not track a static slot for tload.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » tload","id":"170","title":"tload"},"171":{"body":"( Expression::MappingSLoad) Description Compound load for a Solidity mapping element. Equivalent to mstore(0, key); mstore(32, slot); sload(keccak256(0, 64)) but emitted as a single outlined call after the mapping_access_outlining pass recognizes the pattern (it fuses a keccak256_pair — itself produced by mem_opt’s keccak fusion — followed by an sload whose key has a single consumer). Only valid when the intermediate hash is used exclusively by this load. Syntax mapping_sload($key[: ], $slot[: ]) Example let v2 := mapping_sload(v0: i160, v1) Operands Name Type Notes key i256 Mapping key; often narrowed to i160 for address keys. slot i256 The mapping’s declared storage slot. Result and purity Result Purity i256 Pure (per IR; see Description) Annotations None. The fused statement’s effective storage slot is the keccak hash of the key and the declared slot, which is never a compile-time constant; no static_slot hint is surfaced.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mapping_sload","id":"171","title":"mapping_sload"},"172":{"body":"( Expression::DataOffset) Description Offset of a named data segment within the deployed code. The identifier is a string carried in the IR’s id: String field; the linker resolves it to a concrete offset. Syntax dataoffset(\\"\\") Example let v0 := dataoffset(\\"MyContract_deployed\\") Operands None — the identifier is a quoted string literal in the syntax position, not an operand. Result and purity Result Purity i256 Pure Annotations Source field Printed as id: String The quoted identifier in the syntax position (not a comment annotation; it is the expression itself).","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » dataoffset","id":"172","title":"dataoffset"},"173":{"body":"( Expression::DataSize) Description Size of a named data segment within the deployed code, in bytes. The identifier is resolved by the linker. Syntax datasize(\\"\\") Example let v0: i64 := datasize(\\"MyContract_deployed\\") Operands None — the identifier is a quoted string literal in the syntax position, not an operand. Result and purity Result Purity i64 Pure Annotations Source field Printed as id: String The quoted identifier in the syntax position.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » datasize","id":"173","title":"datasize"},"174":{"body":"( Expression::LoadImmutable) Description Read the value of a named immutable variable. Immutables are written once during contract construction by SetImmutable and read afterwards via this expression. Syntax loadimmutable(\\"\\") Example let v0 := loadimmutable(\\"MyContract.owner\\") Operands None — the key is a quoted string literal in the syntax position. Result and purity Result Purity i256 Pure Annotations Source field Printed as key: String The quoted identifier in the syntax position.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » loadimmutable","id":"174","title":"loadimmutable"},"175":{"body":"( Expression::LinkerSymbol) Description Address of an external library, resolved by the linker. The path encodes the library’s source location and identifier. Syntax linkersymbol(\\"\\") Example let v0: i160 := linkersymbol(\\"contracts/Library.sol:L\\") Operands None — the path is a quoted string literal in the syntax position. Result and purity Result Purity i160 Pure Annotations Source field Printed as path: String The quoted path in the syntax position.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » linkersymbol","id":"175","title":"linkersymbol"},"176":{"body":"( Expression::Call; the printer emits func_ when no function name is registered) Description Internal function call. Invokes a user-defined function declared earlier in the same object; the mnemonic is the function’s Yul-level name, or func_ if the printer has no name registered for the FunctionId. Distinct from call and the other EVM call-opcode statements, which cross the contract boundary. Syntax ([$argument_0[: ], $argument_1[: ], …]) Example let v3 := abi_decode_uint256(v0, v1, v2)\\nlet v4, v5 := returns_two(v0) // multi-return via let multi-binding Operands Name Type Notes arguments Vec Zero or more argument values, in declaration order; each operand may carry a : suffix. Result and purity Result Purity One or more values, widths taken from the callee’s declared return types (or the inferred return widths, narrowed via the interprocedural pass). Falls back to i256 when the callee’s returns are unknown to type inference. Effectful — the simplifier treats every call as side-effectful regardless of callee body, so unused call bindings are not DCE’d. The transitive purity of the callee is not tracked at the IR level. Annotations Source field Printed as function: FunctionId The callee’s name in the syntax position (or func_ if the printer has no name registered).","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » ","id":"176","title":""},"177":{"body":"The operations in this section all modify external state: emulated EVM linear memory, persistent storage, or transient storage. They are statements (not expressions) and they are never pure. Simplification and deduplication never reorder them with respect to each other or with respect to reverts; the memory passes treat them as the side-effect boundary for their analyses.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Memory and storage writes","id":"177","title":"Memory and storage writes"},"178":{"body":"( Statement::MStore) Description Write a 32-byte word to emulated EVM linear memory at offset. The word is stored big-endian, matching EVM semantics; the codegen handles the byte swap on PolkaVM’s little-endian RISC-V target. Syntax mstore($offset[: ], $value[: ]) [/* */] Example mstore(v0, v1) // Unknown region; no annotation printed\\nmstore(v2, v3) /* scratch */ // offset proven to land in 0x00..0x3f\\nmstore(v4, v5) /* free_ptr */ // offset is exactly 0x40 Operands Name Type Notes offset i256 Byte offset into linear memory; forward analysis widens to at least i64. value i256 The 32-byte word to store. Narrower values are zero-extended at codegen time. Result and purity Result Purity None Effectful Annotations Source field Printed as region: MemoryRegion /* scratch */ · /* free_ptr */ · /* dynamic */ ( Unknown is suppressed) Assigned at translation time from the constant offset (if any); consumed by mem_opt, FMP propagation, and byte-swap mode selection.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mstore","id":"178","title":"mstore"},"179":{"body":"( Statement::MStore8) Description Write a single byte to emulated EVM linear memory at offset. The low 8 bits of value are stored; the upper bits are ignored. The operation is otherwise identical to mstore: same operand shape, same region tag, same side-effect classification. Syntax mstore8($offset[: ], $value[: ]) [/* */] Example mstore8(v0, v1: i8) Operands Name Type Notes offset i256 Byte offset into linear memory; forward analysis widens to at least i64. value i256 Only the low 8 bits are stored. Often narrowed to i8 by type inference. Result and purity Result Purity None Effectful Annotations Source field Printed as region: MemoryRegion /* scratch */ · /* free_ptr */ · /* dynamic */ ( Unknown is suppressed) Same tagging rules as mstore. Most mstore8s carry an Unknown region in practice because single-byte writes typically target offsets the translator cannot prove constant.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mstore8","id":"179","title":"mstore8"},"18":{"body":"-g Generate source based debug information in the output code file. Useful for debugging and development purposes and disabled by default.","breadcrumbs":"resolc user guide » Command Line Interface » Debug info","id":"18","title":"Debug info"},"180":{"body":"( Statement::MCopy) Description Copy length bytes from src to dest within emulated EVM linear memory. The Yul builtin mcopy maps directly onto this statement; unlike mstore, it does not carry a region tag because the source and destination ranges may straddle multiple regions. Syntax mcopy($dest[: ], $src[: ], $length[: ]) Example mcopy(v0, v1, v2) Operands Name Type Notes dest i256 Destination byte offset in linear memory. src i256 Source byte offset in linear memory. length i256 Number of bytes to copy. Overlapping ranges follow EVM-defined memmove semantics. Result and purity Result Purity None Effectful Annotations None. mcopy carries no region tag because the source and destination ranges may straddle multiple regions, and no static-slot hint because the copy is not storage-bound.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mcopy","id":"180","title":"mcopy"},"181":{"body":"( Statement::SStore) Description Write a 32-byte word to persistent contract storage at key. The operation is the durable counterpart of mstore: the value survives across transactions and is observable to subsequent calls to the contract. Syntax sstore($key[: ], $value[: ]) [/* slot: 0x */] Example sstore(v0, v1)\\nsstore(v2, v3) /* slot: 0x0 */ Operands Name Type Notes key i256 Storage slot. May be a constant slot, a keccak-derived slot for mappings or dynamic arrays, or an arbitrary expression. value i256 The 256-bit word to store. Result and purity Result Purity None Effectful Annotations Source field Printed as static_slot: Option /* slot: 0x */ when set; suppressed otherwise The printer renders the annotation whenever the field is Some, and the deduplicator’s canonicalizer and mapping-fusion analyses consume it as part of the signature. No pass currently writes Some(...), so the annotation is dormant in present-day dumps; when absent, alias and dedup analyses fall back to the conservative “may alias any slot” assumption.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » sstore","id":"181","title":"sstore"},"182":{"body":"( Statement::TStore) Description Write a 32-byte word to transient storage at key. Transient storage is wiped at the end of the transaction, so tstore is the right primitive for per-transaction bookkeeping (reentrancy guards, cached results) without the gas cost of sstore on EVM. On PolkaVM the transient backing store is provided by pallet-revive. Syntax tstore($key[: ], $value[: ]) Example tstore(v0, v1) Operands Name Type Notes key i256 Transient storage slot. value i256 The 256-bit word to store. Result and purity Result Purity None Effectful Annotations None. Unlike sstore, the IR does not track a static slot for tstore: transient storage’s short-lived lifetime makes the slot-aware optimizations less valuable, and the translator does not produce the annotation.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » tstore","id":"182","title":"tstore"},"183":{"body":"( Statement::MappingSStore) Description Compound store for a Solidity mapping element. Equivalent to mstore(0, key); mstore(32, slot); sstore(keccak256(0, 64), value) but emitted as a single outlined statement after the mapping_access_outlining pass recognizes the pattern (it fuses a keccak256_pair followed by an sstore whose key has a single consumer). Only valid when the intermediate hash is not observed by any other statement. Syntax mapping_sstore($key[: ], $slot[: ], $value[: ]) Example mapping_sstore(v0, v1, v2) Operands Name Type Notes key i256 Mapping key. The outlining pass force-widens it to i256, so it always prints at full width, even for address keys. slot i256 The mapping’s declared storage slot. Typically a small constant. value i256 The value to store at the computed storage location. Result and purity Result Purity None Effectful Annotations None. mapping_sstore deliberately drops the static_slot annotation that the original sstore may have carried, because the fused statement’s effective slot is the keccak hash of the key and the declared slot, which is never a compile-time constant.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » mapping_sstore","id":"183","title":"mapping_sstore"},"184":{"body":"Multi-byte memory copies from the EVM-accessible byte sources (code, external code, returndata, embedded data, and calldata) into emulated EVM linear memory. They all take the same shape: a destination memory offset, a source offset, and a length. They are effectful and act as opaque barriers to the memory passes.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Bulk copies","id":"184","title":"Bulk copies"},"185":{"body":"( Statement::CodeCopy) Description Copy length bytes from the currently executing code at offset into emulated EVM linear memory at dest. Reads past the end of code yield zero bytes. Syntax codecopy($dest[: ], $offset[: ], $length[: ]) Example codecopy(v0, v1, v2) Operands Name Type Notes dest i256 Destination byte offset in linear memory. offset i256 Source byte offset in the executing code. length i256 Number of bytes to copy. Result and purity Result Purity None Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » codecopy","id":"185","title":"codecopy"},"186":{"body":"( Statement::ExtCodeCopy) Description Copy length bytes from the code at address starting at offset into emulated EVM linear memory at dest. Reads beyond the code yield zero bytes; non-existent accounts yield all zeros. Syntax extcodecopy($address[: ], $dest[: ], $offset[: ], $length[: ]) Example extcodecopy(v0: i160, v1, v2, v3) Operands Name Type Notes address i256 Account whose code to read; forward analysis widens to at least i160. dest i256 Destination byte offset in linear memory. offset i256 Source byte offset in the external code. length i256 Number of bytes to copy. Result and purity Result Purity None Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » extcodecopy","id":"186","title":"extcodecopy"},"187":{"body":"( Statement::ReturnDataCopy) Description Copy length bytes from the most recent sub-call’s return data starting at offset into emulated EVM linear memory at dest. Per EVM, reads past the return data’s end revert; the memory passes treat this as a potential trap site. Syntax returndatacopy($dest[: ], $offset[: ], $length[: ]) Example returndatacopy(v0, v1, v2) Operands Name Type Notes dest i256 Destination byte offset in linear memory. offset i256 Source byte offset in the return-data buffer. length i256 Number of bytes to copy. Result and purity Result Purity None Effectful (may revert on out-of-range reads, per EVM) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » returndatacopy","id":"187","title":"returndatacopy"},"188":{"body":"( Statement::DataCopy) Description Copy length bytes from an embedded data segment starting at offset into emulated EVM linear memory at dest. The source segment is resolved by the linker, typically used to pull constants compiled into the bytecode into runtime memory. Syntax datacopy($dest[: ], $offset[: ], $length[: ]) Example datacopy(v0, v1, v2) Operands Name Type Notes dest i256 Destination byte offset in linear memory. offset i256 Source byte offset in the data segment. length i256 Number of bytes to copy. Result and purity Result Purity None Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » datacopy","id":"188","title":"datacopy"},"189":{"body":"( Statement::CallDataCopy) Description Copy length bytes from the current call’s calldata starting at offset into emulated EVM linear memory at dest. Reads past the end of calldata yield zero bytes. Syntax calldatacopy($dest[: ], $offset[: ], $length[: ]) Example calldatacopy(v0, v1, v2) Operands Name Type Notes dest i256 Destination byte offset in linear memory. offset i256 Source byte offset in calldata. length i256 Number of bytes to copy. Result and purity Result Purity None Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » calldatacopy","id":"189","title":"calldatacopy"},"19":{"body":"--link [--libraries ] In Solidity, 3 things can happen with libraries: They are not externally callable and thus can be inlined. The solc Solidity optimizer inlines those (usually the case). Note: resolc always activates the solc Solidity optimizer. If the solc Solidity optimizer is disabled or for some reason fails to inline them (both rare), they are not inlined and require linking. They are externally callable but still linked at compile time. This is the case if at compile time the library address is known (i.e. --libraries supplied in CLI or the corresponding setting in STD JSON input). They are linked at deploy time. This happens when the compiler does not know the library address (i.e. --libraries flag is missing or the provided libraries are incomplete, same for STD JSON input). This case is rare because it’s discourage and should never be used by production dApps. In cases 1.2 and 3: Some of the produced code blobs will be in the “unlinked” raw ELF object format and not yet deployable. To make them deployable, they need to be “linked” (done using the resolc --link linker mode explained below). The compiler emitted DELEGATECALL instructions to call non-inlined (unlinked) libraries. The contract deployer must make sure to deploy any libraries prior to contract deployment. Warning Using deploy time linking is officially discouraged. Mainly due to bytecode hashes changing after the fact. We decided to support it in resolc regardless, due to popular request. Similar to how it works in solc, --libraries may be used to provide libraries during linking mode. Unlike with solc, where linking implies a simple string substitution mechanism, resolc needs to resolve actual missing ELF symbols. This is due to how factory dependencies work in PVM. As a consequence, it isn’t sufficient to just provide the unlinked blobs to the linker. Instead, they must be provided in the exact same directory structure the Solidity source code was found during compile time. Example: The contract src/foo/bar.sol:Bar is involved in deploy time linking. It may be a factory dependency. The contract blob needs to be provided inside a relative src/foo/ directory to --link. Otherwise symbol resolution may fail. Note Tooling is supposed to take care of this. In the future, we may append explicit linkage data to simplify the deploy time linking feature.","breadcrumbs":"resolc user guide » Command Line Interface » Deploy time linking","id":"19","title":"Deploy time linking"},"190":{"body":"The statements that bind SSA values, hold loose expressions evaluated for their side effects, and write to immutable storage. Every pure expression in this reference’s earlier sections appears on the right-hand side of one of these statements (almost always let).","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Bindings and wrappers","id":"190","title":"Bindings and wrappers"},"191":{"body":"( Statement::Let) Description SSA binding: evaluate an expression and bind its result(s) to a list of fresh value ids. The let statement is the only mechanism by which pure expressions enter the value namespace; every v in a dump was produced by a let (or by a value-yielding control-flow statement or by a parameter at function entry). Syntax let $binding_0[, $binding_1, …] := $expression Example let v3 := add(v0, v1)\\nlet v4, v5 := if v2 [v0, v1] { … } else { … } // multi-binding from a value-yielding If Operands Name Type Notes bindings Vec One or more fresh SSA ids to bind. Most expressions produce one value; control-flow statements may produce several. value Expression The right-hand side; see any of the Pure expression entries. Result and purity Result Purity None directly — the bound ids carry the expression’s result(s) Effectful (binding establishment); the right-hand side’s purity is independent Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » let","id":"191","title":"let"},"192":{"body":"( Statement::Expression) Description Wraps an expression evaluated for its observable consequences but whose value is not bound. Typically a zero-return (void) user-defined function call ( Expression::Call) evaluated for its side effects, or the discarded void result of a Yul builtin used as a statement (a value-producing expression is bound by a let instead). EVM external calls ( call, delegatecall, etc.) and contract creation ( create, create2) translate to dedicated Statement::ExternalCall and Statement::Create variants, not through this wrapper. Syntax $expression Example update_balance(v0) // void function called for its side effects Operands Name Type Notes expression Expression Any expression; result is discarded. Result and purity Result Purity None Effectful (per its statement position) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Expression statement","id":"192","title":"Expression statement"},"193":{"body":"( Statement::SetImmutable) Description Write an immutable variable during contract construction. Immutables are written once in the constructor and read later via loadimmutable. The key is a string identifier resolved by the linker. Syntax setimmutable(\\"\\", $value[: ]) Example setimmutable(\\"MyContract.owner\\", v0) Operands Name Type Notes value i256 The value to store; the key is a quoted string literal in the syntax position. Result and purity Result Purity None Effectful Annotations Source field Printed as key: String The quoted identifier in the syntax position.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » setimmutable","id":"193","title":"setimmutable"},"194":{"body":"The IR’s control flow is structured: if, switch, and for are statements with explicit nested regions, each carrying input values and yielding output values. The jump-like statements ( break, continue, leave) are scoped to their nearest enclosing construct. Nested blocks create lexical scope without otherwise changing control flow.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Structured control flow","id":"194","title":"Structured control flow"},"195":{"body":"( Statement::If) Description Conditional execution with optional value yields. The then region runs when condition is non-zero; the else region runs otherwise. If outputs is non-empty, both regions must yield the same number of values and the statement is bound by a let. Syntax if $condition[: ] [[$input_0, $input_1, …]] { … } [else { … }] Example if v0: i1 { sstore(v1, v2)\\n} let v5, v6 := if v3: i1 [v1, v2] { let v7: i64 := 0x1 // add widens its operands to the i64 register width let v8 := add(v2, v7: i64) yield v1, v8\\n} else { yield v1, v2\\n} Operands Name Type Notes condition i256 Branch selector; non-zero takes the then region. Often narrowed to i1. inputs Vec Values threaded into both regions, printed in square brackets after the condition. (regions) — The then_region is mandatory; the else_region is optional and, when absent, implicitly yields the inputs unchanged. Result and purity Result Purity None for the statement form; for the value-yielding form, one value per outputs binding, types taken from the yielded values Effectful (control flow) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » if","id":"195","title":"if"},"196":{"body":"( Statement::Switch) Description Multi-way dispatch on a scrutinee value. Each case matches a specific constant and runs its region; an optional default region catches non-matching values. Like if, switch may yield values via outputs and accept thread-through values via inputs. Syntax switch $scrutinee[: ] [[$input_0, …]]\\ncase 0x { …\\n}\\n[case 0x { …\\n} …]\\n[default { …\\n}] Example switch v0\\ncase 0x0 { sstore(v1, v2)\\n}\\ncase 0x1 { sstore(v1, v3)\\n}\\ndefault { invalid()\\n} Operands Name Type Notes scrutinee i256 The value to compare against each case. inputs Vec Values threaded into every case and default region. cases Vec Each case carries a constant value: BigUint and a region. (default) — Optional fall-through region. Result and purity Result Purity None for the statement form; one value per outputs binding for the value-yielding form Effectful (control flow) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » switch","id":"196","title":"switch"},"197":{"body":"( Statement::For) Description Structured loop with explicit loop-carried variables. Each iteration evaluates condition_statements followed by condition; if the condition is non-zero, the body region runs, then the post region runs, and the loop iterates. Loop-carried variables are passed as SSA values through each region. break exits the loop and continue jumps to the post region. Syntax for { $variable_0 := $initial_0[, …] } [// condition statements: …] condition: $condition post [($post_input_variable_0[, …])] { … } body { … body … } Example let v0: i1 := 0x0\\nlet v6 := for { v1 := v0: i1 } // condition statements: let v2: i8 := 0xa condition: lt(v1, v2: i8) post (v3) { let v4: i64 := 0x1 let v5 := add(v3, v4: i64) yield v5 } body { sstore(v1, v1) 0x0: void yield v1 } Operands Name Type Notes initial_values Vec Starting values for the loop-carried variables. loop_variables Vec SSA ids visible inside condition, body, and post. condition_statements Vec Statements evaluated each iteration before the condition expression; emitted into the loop header block. Printed only when non-empty, behind a // condition statements: comment. condition Expression Re-evaluated each iteration; non-zero continues, zero exits. body Region Loop body; yields current loop-carried values. post_input_variables Vec Input SSA ids for the post region (one per loop-carried variable); receive the body’s yielded values merged with continue-site values via phi nodes in the LLVM codegen. post Region Runs after each body iteration (and after continue); yields updated loop-carried values. outputs Vec Final loop-carried values after exit. Result and purity Result Purity None for the statement form; one value per outputs binding for the value-yielding form Effectful (control flow) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » for","id":"197","title":"for"},"198":{"body":"( Statement::Break) Description Exit the innermost enclosing for loop. Carries the current values of loop-carried variables at the break point; these become the loop’s outputs. Syntax break Example if v0 { break [v1, v2] } Operands The loop-carried values: Vec print in brackets when non-empty (e.g. break [v1, v2]). Result and purity Result Purity None Effectful (control flow) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » break","id":"198","title":"break"},"199":{"body":"( Statement::Continue) Description Skip to the post region of the innermost enclosing for loop. Like break, carries the current values of loop-carried variables internally. Syntax continue Example if v0 { continue [v1, v2] } Operands The loop-carried values print in brackets when non-empty (e.g. continue [v1, v2]). Result and purity Result Purity None Effectful (control flow) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » continue","id":"199","title":"continue"},"2":{"body":"Head to contracts.polkadot.io for more general information about contracts on Polkadot.","breadcrumbs":"Welcome » Other Polkadot contracts resources","id":"2","title":"Other Polkadot contracts resources"},"20":{"body":"The resolc compiler driver is published as an NPM package under @parity/resolc. It’s usable from Node.js code or directly from the command line: npx @parity/resolc@latest --bin crates/integration/contracts/flipper.sol -o /tmp/out Note While the npm package makes a nice portable option, it doesn’t expose all options.","breadcrumbs":"resolc user guide » JS NPM package » JS NPM package","id":"20","title":"JS NPM package"},"200":{"body":"( Statement::Leave) Description Exit the current function, returning the listed values as the function’s return values. The Yul-level leave keyword translates directly to this statement; the inlining pass eliminates intra-function leaves where possible via the exit-flag transformation. Syntax leave [[$value_0[: ], $value_1[: ], …]] Example leave [v0, v1] // returns v0 and v1 from the function\\nleave // returns nothing (void function) Operands Name Type Notes return_values Vec Empty for void functions; otherwise one entry per declared return. Result and purity Result Purity None Effectful (control flow) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » leave","id":"200","title":"leave"},"201":{"body":"( Statement::Block) Description A lexical scope without conditional or iterative behavior. The body is a region; control falls through after the region’s statements complete. Used to bound the visibility of inner bindings. Syntax { …\\n} Example { let v0 := add(v1, v2) sstore(v3, v0)\\n} // v0 is no longer in scope here Operands None — the body is a region, not an operand. Result and purity Result Purity None Effectful (per the body’s contents) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » Nested block","id":"201","title":"Nested block"},"202":{"body":"Statements that cross the contract boundary: external calls, contract creation, and event log emission. All produce or rely on external state and act as barriers to memory and storage analyses.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » External interaction","id":"202","title":"External interaction"},"203":{"body":"( Statement::ExternalCall with CallKind::Call) Description Standard external call that may transfer value. Reads args_length bytes from emulated EVM linear memory at args_offset as calldata, executes the target, and writes up to ret_length bytes of return data into linear memory at ret_offset. The boolean result indicates success. Syntax let $result := call($gas[: ], $address[: ], $value[: ], $args_offset[: ], $args_length[: ], $ret_offset[: ], $ret_length[: ]) Example let v8 := call(v0: i64, v1: i160, v2, v3: i64, v4: i64, v5: i64, v6: i64) Operands Name Type Notes gas i256 Gas to forward to the target; forward analysis widens to at least i64. address i256 Callee address; forward analysis widens to at least i160. value i256 Wei to transfer with the call. args_offset i256 Calldata source offset in linear memory; forward analysis widens to at least i64. args_length i256 Calldata length in bytes; forward analysis widens to at least i64. ret_offset i256 Return-data destination offset in linear memory; forward analysis widens to at least i64. ret_length i256 Maximum return-data length; forward analysis widens to at least i64. Result and purity Result Purity i256 (success flag: 1 on success, 0 on revert/error; narrowable to i1) Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » call","id":"203","title":"call"},"204":{"body":"( Statement::ExternalCall with CallKind::CallCode) Description Deprecated EVM opcode that executes the callee’s code in the caller’s context but with the callee’s storage. Not supported by the newyork backend (codegen rejects it); use delegatecall instead. Syntax let $result := callcode($gas[: ], $address[: ], $value[: ], $args_offset[: ], $args_length[: ], $ret_offset[: ], $ret_length[: ]) Example let v8 := callcode(v0: i64, v1: i160, v2, v3: i64, v4: i64, v5: i64, v6: i64) Operands Same shape as call. Result and purity Result Purity i256 (success flag; narrowable to i1) Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » callcode","id":"204","title":"callcode"},"205":{"body":"( Statement::ExternalCall with CallKind::DelegateCall) Description Execute the callee’s code in the caller’s context: same storage, same sender, same call value. The standard mechanism for library calls and proxy patterns. No value operand (the caller’s call value is inherited). Syntax let $result := delegatecall($gas[: ], $address[: ], $args_offset[: ], $args_length[: ], $ret_offset[: ], $ret_length[: ]) Example let v7 := delegatecall(v0: i64, v1: i160, v2: i64, v3: i64, v4: i64, v5: i64) Operands Same shape as call minus the value operand. Result and purity Result Purity i256 (success flag; narrowable to i1) Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » delegatecall","id":"205","title":"delegatecall"},"206":{"body":"( Statement::ExternalCall with CallKind::StaticCall) Description Read-only external call. Any state modification in the callee (including nested calls) causes the call to revert. No value operand. Syntax let $result := staticcall($gas[: ], $address[: ], $args_offset[: ], $args_length[: ], $ret_offset[: ], $ret_length[: ]) Example let v7 := staticcall(v0: i64, v1: i160, v2: i64, v3: i64, v4: i64, v5: i64) Operands Same shape as call minus the value operand. Result and purity Result Purity i256 (success flag; narrowable to i1) Effectful (no state writes, but still an external boundary and may revert) Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » staticcall","id":"206","title":"staticcall"},"207":{"body":"( Statement::Create with CreateKind::Create) Description Deploy a new contract with the given init-code bytes, transferring value wei from the caller. The new contract’s address is derived from the caller’s address and nonce; on failure the result is 0. Syntax let $result := create($value[: ], $offset[: ], $length[: ]) Example let v4 := create(v0, v1: i64, v2: i64) Operands Name Type Notes value i256 Wei to transfer to the new contract. offset i256 Linear-memory offset of the init code; forward analysis widens to at least i64. length i256 Length of the init code in bytes; forward analysis widens to at least i64. Result and purity Result Purity i256 (created address; narrowable to i160 on success, 0 on failure) Effectful Annotations None.","breadcrumbs":"Developer Guide » The newyork optimizer » IR reference » create","id":"207","title":"create"},"208":{"body":"( Statement::Create with CreateKind::Create2) Description Deploy a new contract with a deterministic address derived from the caller’s address, the salt, and the init-code hash. Same operand shape as create plus an additional salt. Syntax let $result := create2($value[: ], $offset[: ], $length[: ], $salt[: