Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/PVS/while/   (PVS Prover Version 6.0.9©)  Datei vom 28.9.2014 mit Größe 1 kB image not shown  

Quelle  Instruction.pvs

  Sprache: PVS
 

%------------------------------------------------------------------------------
% An Instruction Set for an Abstract Machine for while
%
% All references are to HR and F Nielson "Semantics with Applications:
% A Formal Introduction", John Wiley & Sons, 1992. (revised edition
% available: http://www.daimi.au.dk/~hrn )
%
%     Author: David Lester, Manchester University, NIA, Université Perpignan
%
%     Version 1.0            25/12/07  Initial Version
%------------------------------------------------------------------------------

Instruction[V:TYPE+]: THEORY

BEGIN

  Instruction: DATATYPE
  BEGIN
    PUSH(n:int)                     : PUSH?
    FETCH(x1:V)                     : FETCH?
    UNARY(f1:[int->int])            : UNARY?
    BINARY(f2:[[int,int]->int])     : BINARY?
    STORE(x2:V)                     : STORE?
    NOOP                            : NOOP?
    BRANCH(c1,c2:list[Instruction]) : BRANCH?
    LOOP(c3,c4:list[Instruction])   : LOOP?
  END Instruction

  Code: TYPE+ = list[Instruction] CONTAINING null

  i,j: VAR int

  PUSH_TRUE:  MACRO Instruction = PUSH(b2n(TRUE))
  PUSH_FALSE: MACRO Instruction = PUSH(b2n(FALSE))
  ADD:   MACRO Instruction = BINARY(lambda i,j: i+j)
  SUB:   MACRO Instruction = BINARY(lambda i,j: i-j)
  MUL:   MACRO Instruction = BINARY(lambda i,j: i*j)
  EQ:    MACRO Instruction = BINARY(lambda i,j: b2n(i=j))
  LE:    MACRO Instruction = BINARY(lambda i,j: b2n(i<=j))
  NEG:   MACRO Instruction = UNARY(lambda i: 1-i)
  B_AND: MACRO Instruction = MUL

END Instruction

Messung V0.5 in Prozent
C=75 H=56 G=65

¤ Dauer der Verarbeitung: 0.10 Sekunden  (vorverarbeitet am  2026-06-15) ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.