K-Go: An executable formal semantics of Go language in K framework

IET Blockchain Pub Date : 2023-03-13 DOI:10.1049/blc2.12024
Can Zhao, Qin Liu, Zonghua Hu, Ze Yu, Dejun Wang, Bo Meng
{"title":"K-Go: An executable formal semantics of Go language in K framework","authors":"Can Zhao,&nbsp;Qin Liu,&nbsp;Zonghua Hu,&nbsp;Ze Yu,&nbsp;Dejun Wang,&nbsp;Bo Meng","doi":"10.1049/blc2.12024","DOIUrl":null,"url":null,"abstract":"<p>Go is a relatively new programming language and has become one of the most important programming languages used widely in blockchain. A formal semantics plays an important role in program synthesis, analysis and verification. The existed formal semantics of Go are not executable and do not cover the core features, hence, this paper presents an executable formal semantics for Go, called K-Go, using rewriting logic in <math>\n <semantics>\n <mi>K</mi>\n <annotation>$\\mathbb{K}$</annotation>\n </semantics></math> framework to make sure the semantics is both executable and applicable. K-Go includes syntax, configuration and rules and covers the declaration and definition of basic types, basic expression, concurrency, main statement data reading and writing based on channel. K-Go is validated by test set with 100% semantic coverage based on the official test suite. The evaluation experiment shows that K-Go is correct. Using formal semantics of Go language, building Go program synthesis, analysis and verification tools is easy for analyzing more characteristics of Go programs.</p>","PeriodicalId":100650,"journal":{"name":"IET Blockchain","volume":"3 2","pages":"61-73"},"PeriodicalIF":0.0000,"publicationDate":"2023-03-13","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"https://onlinelibrary.wiley.com/doi/epdf/10.1049/blc2.12024","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"IET Blockchain","FirstCategoryId":"1085","ListUrlMain":"https://onlinelibrary.wiley.com/doi/10.1049/blc2.12024","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

Go is a relatively new programming language and has become one of the most important programming languages used widely in blockchain. A formal semantics plays an important role in program synthesis, analysis and verification. The existed formal semantics of Go are not executable and do not cover the core features, hence, this paper presents an executable formal semantics for Go, called K-Go, using rewriting logic in K $\mathbb{K}$ framework to make sure the semantics is both executable and applicable. K-Go includes syntax, configuration and rules and covers the declaration and definition of basic types, basic expression, concurrency, main statement data reading and writing based on channel. K-Go is validated by test set with 100% semantic coverage based on the official test suite. The evaluation experiment shows that K-Go is correct. Using formal semantics of Go language, building Go program synthesis, analysis and verification tools is easy for analyzing more characteristics of Go programs.

Abstract Image

查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
K-Go:K框架下Go语言的可执行形式语义
Go是一种相对较新的编程语言,已成为区块链中广泛使用的最重要的编程语言之一。形式语义在程序综合、分析和验证中起着重要作用。由于Go已有的形式语义是不可执行的,并且没有覆盖核心特征,因此,本文在K$\mathbb{K}$框架中使用重写逻辑,提出了一种Go的可执行形式语义K-Go,以确保该语义是可执行的和可应用的。K-Go包括语法、配置和规则,涵盖了基本类型的声明和定义、基本表达式、并发性、基于通道的主语句数据读写。K-Go通过基于官方测试套件的100%语义覆盖的测试集进行验证。评价实验表明K-Go是正确的。利用Go语言的形式语义,构建Go程序的综合、分析和验证工具,可以方便地分析Go程序的更多特征。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
CiteScore
1.80
自引率
0.00%
发文量
0
期刊最新文献
Blockchain transaction data mining and its applications Research on airport baggage anomaly retention detection technology based on machine vision, edge computing, and blockchain Data‐sharing strategies in medical consortium based on master‐slave multichain and federated learning RON‐based cross‐chain routing optimization strategy in metaverse Leveraging ontochains for distributed public transit ticketing: An investigation with the system for ticketing ubiquity with blockchains
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1