I want to understand the purpose of tags in EVM assembly and their relationship with Solidity function.

pragma solidity ^0.5.1;
   import './Mod.sol';
   contract MOFTest{
       ModifiedBank mb;
       constructor(address payable addressOfBank, uint amount) public {}
       function deposit (uint amount )  payable public {

For the above contract, I have downloaded the assembly part from the Remix IDE and attached it with the postEVM ASM_opcodes and tags.

I found that if I have a constructor then Remix IDE will have only 2 tags but now I have 2 functions and I found that there are 5 tags. Kindly explain me what is the purpose of tags and what is their relationship with Solidity functions? Also the tags are appearing in a haphazard manner, first tag1 and tag2 , then again tag1 and tag2, after that Remix IDE shows tag4, and then tag3 & tag5.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.