openpower-isa.git
3 months agoliboppc: introduce simple check oppc
Dmitry Selyutin [Wed, 17 Jan 2024 15:28:34 +0000 (18:28 +0300)]
liboppc: introduce simple check

3 months agoliboppc: introduce oppc.h header
Dmitry Selyutin [Tue, 16 Jan 2024 19:11:05 +0000 (22:11 +0300)]
liboppc: introduce oppc.h header

3 months agooppc/code: fix switch statements
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: fix switch statements

3 months agooppc/ast: support REAL_PAGE_SIZE
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/ast: support REAL_PAGE_SIZE

3 months agooppc/code: fix switch statement
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: fix switch statement

3 months agooppc/code: supply transient for attr exprs
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: supply transient for attr exprs

3 months agooppc/code: handle statements everywhere
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: handle statements everywhere

3 months agooppc/code: handle call statements
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: handle call statements

3 months agooppc/code: silence unused insn
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: silence unused insn

3 months agooppc/code: translate None to NULL
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: translate None to NULL

3 months agooppc/code: refactor binary and unary exprs
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: refactor binary and unary exprs

3 months agooppc: emit header include directive
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc: emit header include directive

3 months agooppc/code: refactor declarations order
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: refactor declarations order

3 months agooppc: refactor output
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc: refactor output

3 months agooppc/code: support dynamic operands
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: support dynamic operands

3 months agooppc/code: emit only function body
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: emit only function body

3 months agooppc: rename NotEq to Ne
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc: rename NotEq to Ne

3 months agooppc: skip bogus sync instruction
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc: skip bogus sync instruction

3 months agooppc/code: supply transient to unary exprs
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: supply transient to unary exprs

3 months agoinsndb/core: fix operands iteration
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
insndb/core: fix operands iteration

3 months agooppc/ast: remove invalid FPR
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/ast: remove invalid FPR

3 months agooppc/code: prefix TRAP call
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: prefix TRAP call

3 months agooppc/code: generalize casts
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: generalize casts

3 months agooppc/code: insert footer line break
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: insert footer line break

3 months agooppc/code: adopt pseudocode calls to C realities
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: adopt pseudocode calls to C realities

3 months agooppc/code: deprecate redundant class variable
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: deprecate redundant class variable

3 months agooppc/code: check for symbol presense in pseudocode
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: check for symbol presense in pseudocode

3 months agooppc/code: do not emit pseudocode unless necessary
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/code: do not emit pseudocode unless necessary

3 months agooppc/pseudocode: allow to check whether node is present
Dmitry Selyutin [Tue, 16 Jan 2024 19:09:45 +0000 (22:09 +0300)]
oppc/pseudocode: allow to check whether node is present

3 months agooppc/code: deprecate redundant ampersands
Dmitry Selyutin [Sun, 14 Jan 2024 20:52:36 +0000 (23:52 +0300)]
oppc/code: deprecate redundant ampersands

3 months agooppc/code: assume 1 bit for subscript expr
Dmitry Selyutin [Sun, 14 Jan 2024 20:49:17 +0000 (23:49 +0300)]
oppc/code: assume 1 bit for subscript expr

3 months agooppc/code: fix comparisons
Dmitry Selyutin [Sun, 14 Jan 2024 20:48:00 +0000 (23:48 +0300)]
oppc/code: fix comparisons

3 months agooppc/code: fix subscript exprs
Dmitry Selyutin [Sun, 14 Jan 2024 20:29:29 +0000 (23:29 +0300)]
oppc/code: fix subscript exprs

3 months agooppc/code: support TRAP
Dmitry Selyutin [Sun, 14 Jan 2024 20:25:11 +0000 (23:25 +0300)]
oppc/code: support TRAP

3 months agooppc/code: support GRP0
Dmitry Selyutin [Sun, 14 Jan 2024 20:17:22 +0000 (23:17 +0300)]
oppc/code: support GRP0

3 months agooppc/code: support basic fields initialization
Dmitry Selyutin [Sun, 14 Jan 2024 20:00:49 +0000 (23:00 +0300)]
oppc/code: support basic fields initialization

3 months agooppc/code: deprecate redundant node arguments
Dmitry Selyutin [Sun, 14 Jan 2024 19:13:03 +0000 (22:13 +0300)]
oppc/code: deprecate redundant node arguments

3 months agooppc/code: introduce insn argument
Dmitry Selyutin [Sun, 14 Jan 2024 18:57:13 +0000 (21:57 +0300)]
oppc/code: introduce insn argument

3 months agooppc: pass insndb record
Dmitry Selyutin [Sun, 14 Jan 2024 18:56:05 +0000 (21:56 +0300)]
oppc: pass insndb record

3 months agooppc: print C code instead of pseudocode
Dmitry Selyutin [Sun, 14 Jan 2024 18:51:34 +0000 (21:51 +0300)]
oppc: print C code instead of pseudocode

3 months agooppc/code: support multiple assignments
Dmitry Selyutin [Sun, 14 Jan 2024 18:41:16 +0000 (21:41 +0300)]
oppc/code: support multiple assignments

3 months agooppc/code: support string literals
Dmitry Selyutin [Sun, 14 Jan 2024 18:23:43 +0000 (21:23 +0300)]
oppc/code: support string literals

3 months agooppc: support attributes
Dmitry Selyutin [Sun, 14 Jan 2024 18:12:03 +0000 (21:12 +0300)]
oppc: support attributes

3 months agooppc: decouple attribute name
Dmitry Selyutin [Sun, 14 Jan 2024 18:05:05 +0000 (21:05 +0300)]
oppc: decouple attribute name

3 months agooppc/code: rename ccall into call
Dmitry Selyutin [Sun, 14 Jan 2024 15:35:32 +0000 (18:35 +0300)]
oppc/code: rename ccall into call

3 months agooppc/code: support leave keyword
Dmitry Selyutin [Sun, 14 Jan 2024 14:43:19 +0000 (17:43 +0300)]
oppc/code: support leave keyword

3 months agooppc/code: support more special symbols
Dmitry Selyutin [Sun, 14 Jan 2024 14:40:46 +0000 (17:40 +0300)]
oppc/code: support more special symbols

3 months agooppc/code: fix if exprs check
Dmitry Selyutin [Sun, 14 Jan 2024 14:19:58 +0000 (17:19 +0300)]
oppc/code: fix if exprs check

3 months agooppc/pseudocode: support switches
Dmitry Selyutin [Sun, 14 Jan 2024 14:15:19 +0000 (17:15 +0300)]
oppc/pseudocode: support switches

3 months agooppc/pseudocode: always use keywords for emit calls
Dmitry Selyutin [Sun, 14 Jan 2024 13:50:30 +0000 (16:50 +0300)]
oppc/pseudocode: always use keywords for emit calls

3 months agooppc/code: support concatenation
Dmitry Selyutin [Sun, 14 Jan 2024 13:44:25 +0000 (16:44 +0300)]
oppc/code: support concatenation

3 months agooppc/code: support unsigned comparisons
Dmitry Selyutin [Sun, 14 Jan 2024 13:43:00 +0000 (16:43 +0300)]
oppc/code: support unsigned comparisons

3 months agooppc/code: rename oppc_int to oppc_value
Dmitry Selyutin [Sun, 14 Jan 2024 13:34:36 +0000 (16:34 +0300)]
oppc/code: rename oppc_int to oppc_value

3 months agooppc/code: support ternary expr inside binary and unary
Dmitry Selyutin [Sun, 14 Jan 2024 13:22:34 +0000 (16:22 +0300)]
oppc/code: support ternary expr inside binary and unary

3 months agooppc/code: align ternary if expressions
Dmitry Selyutin [Sun, 14 Jan 2024 13:20:37 +0000 (16:20 +0300)]
oppc/code: align ternary if expressions

3 months agooppc/code: eliminate redundant pseudocode
Dmitry Selyutin [Sun, 14 Jan 2024 12:56:43 +0000 (15:56 +0300)]
oppc/code: eliminate redundant pseudocode

3 months agooppc/code: emit symbol pseudocode
Dmitry Selyutin [Sun, 14 Jan 2024 12:46:49 +0000 (15:46 +0300)]
oppc/code: emit symbol pseudocode

3 months agooppc/code: drop explicit ctx argument
Dmitry Selyutin [Sun, 14 Jan 2024 12:30:42 +0000 (15:30 +0300)]
oppc/code: drop explicit ctx argument

3 months agooppc/code: introduce ccall
Dmitry Selyutin [Sun, 14 Jan 2024 12:24:39 +0000 (15:24 +0300)]
oppc/code: introduce ccall

3 months agooppc/code: introduce transient
Dmitry Selyutin [Sun, 14 Jan 2024 11:25:17 +0000 (14:25 +0300)]
oppc/code: introduce transient

3 months agooppc/ast: hash node by id
Dmitry Selyutin [Sun, 14 Jan 2024 12:17:18 +0000 (15:17 +0300)]
oppc/ast: hash node by id

3 months agooppc/main: parse all insndb instructions
Dmitry Selyutin [Sat, 13 Jan 2024 15:30:02 +0000 (18:30 +0300)]
oppc/main: parse all insndb instructions

3 months agooppc/code: convert everything into calls
Dmitry Selyutin [Sat, 13 Jan 2024 12:33:48 +0000 (15:33 +0300)]
oppc/code: convert everything into calls

3 months agooppc/util: simplify empty statements
Dmitry Selyutin [Sat, 13 Jan 2024 12:30:54 +0000 (15:30 +0300)]
oppc/util: simplify empty statements

3 months agooppc/parser: check for regs in trailerlist
Dmitry Selyutin [Fri, 12 Jan 2024 20:47:00 +0000 (23:47 +0300)]
oppc/parser: check for regs in trailerlist

3 months agooppc/code: support ternary conditionals
Dmitry Selyutin [Fri, 12 Jan 2024 20:23:36 +0000 (23:23 +0300)]
oppc/code: support ternary conditionals

3 months agooppc/code: support if exprs
Dmitry Selyutin [Fri, 12 Jan 2024 20:16:17 +0000 (23:16 +0300)]
oppc/code: support if exprs

3 months agooppc/pseudocode: simplify call arguments
Dmitry Selyutin [Fri, 12 Jan 2024 20:13:34 +0000 (23:13 +0300)]
oppc/pseudocode: simplify call arguments

3 months agooppc/code: support for exprs
Dmitry Selyutin [Fri, 12 Jan 2024 20:07:18 +0000 (23:07 +0300)]
oppc/code: support for exprs

3 months agooppc/code: support calls
Dmitry Selyutin [Fri, 12 Jan 2024 19:52:30 +0000 (22:52 +0300)]
oppc/code: support calls

3 months agooppc/code: support subscript assignments
Dmitry Selyutin [Fri, 12 Jan 2024 19:47:48 +0000 (22:47 +0300)]
oppc/code: support subscript assignments

3 months agooppc/code: support subscript exprs
Dmitry Selyutin [Fri, 12 Jan 2024 19:28:58 +0000 (22:28 +0300)]
oppc/code: support subscript exprs

3 months agooppc/code: support XLEN
Dmitry Selyutin [Fri, 12 Jan 2024 19:33:05 +0000 (22:33 +0300)]
oppc/code: support XLEN

3 months agooppc: consider subscripts exprs
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc: consider subscripts exprs

3 months agooppc/code: support repeat expr
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc/code: support repeat expr

3 months agooppc/code: simplify exprs and regs
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc/code: simplify exprs and regs

3 months agooppc/code: support bitwise operations
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc/code: support bitwise operations

3 months agooppc/code: support simple conditions
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc/code: support simple conditions

3 months agooppc/code: support binary mul/div/mod
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc/code: support binary mul/div/mod

3 months agooppc/code: support binary add/sub
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc/code: support binary add/sub

3 months agooppc/code: refactor unary exprs
Dmitry Selyutin [Fri, 12 Jan 2024 19:24:22 +0000 (22:24 +0300)]
oppc/code: refactor unary exprs

3 months agooppc/code: support simple constant unary exprs
Dmitry Selyutin [Wed, 10 Jan 2024 21:09:37 +0000 (00:09 +0300)]
oppc/code: support simple constant unary exprs

3 months agooppc/code: support simple constant assignments
Dmitry Selyutin [Wed, 10 Jan 2024 20:49:22 +0000 (23:49 +0300)]
oppc/code: support simple constant assignments

3 months agooppc/code: introduce header and footer
Dmitry Selyutin [Wed, 10 Jan 2024 20:43:59 +0000 (23:43 +0300)]
oppc/code: introduce header and footer

3 months agooppc: introduce C generator skeleton
Dmitry Selyutin [Tue, 9 Jan 2024 21:26:03 +0000 (00:26 +0300)]
oppc: introduce C generator skeleton

3 months agooppc: check for special symbols
Dmitry Selyutin [Tue, 9 Jan 2024 19:48:26 +0000 (22:48 +0300)]
oppc: check for special symbols

3 months agooppc: decouple common code
Dmitry Selyutin [Tue, 9 Jan 2024 18:23:44 +0000 (21:23 +0300)]
oppc: decouple common code

3 months agooppc: simplify ternary conditionals
Dmitry Selyutin [Tue, 9 Jan 2024 18:29:45 +0000 (21:29 +0300)]
oppc: simplify ternary conditionals

3 months agooppc: decouple pseudocode module
Dmitry Selyutin [Tue, 9 Jan 2024 18:08:41 +0000 (21:08 +0300)]
oppc: decouple pseudocode module

3 months agooppc: decouple call name class
Dmitry Selyutin [Tue, 9 Jan 2024 15:49:56 +0000 (18:49 +0300)]
oppc: decouple call name class

3 months agooppc: rename Assign classes
Dmitry Selyutin [Mon, 8 Jan 2024 20:26:32 +0000 (23:26 +0300)]
oppc: rename Assign classes

3 months agooppc: swap declaration
Dmitry Selyutin [Mon, 8 Jan 2024 13:19:38 +0000 (16:19 +0300)]
oppc: swap declaration

3 months agooppc: introduce GPRZero class
Dmitry Selyutin [Mon, 8 Jan 2024 12:48:13 +0000 (15:48 +0300)]
oppc: introduce GPRZero class

3 months agopywriter: convert pcode to tree and back to pcode
Dmitry Selyutin [Mon, 8 Jan 2024 08:34:02 +0000 (11:34 +0300)]
pywriter: convert pcode to tree and back to pcode

3 months agooppc: introduce openpower pseudocode
Dmitry Selyutin [Sun, 7 Jan 2024 22:57:51 +0000 (01:57 +0300)]
oppc: introduce openpower pseudocode

3 months agoinsndb/db: update walker
Dmitry Selyutin [Fri, 5 Jan 2024 20:39:48 +0000 (23:39 +0300)]
insndb/db: update walker

3 months agofixedsync.mdwn: change sync from v3.1B version to v3.0B version
Jacob Lifshay [Tue, 16 Jan 2024 09:18:58 +0000 (01:18 -0800)]
fixedsync.mdwn: change sync from v3.1B version to v3.0B version

to use the v3.1B version requires fixing fields.text to use the new
L and SC fields, which requires deciphering all the places where the
current L (named L2) field is used and making sure they'll be correct still.

using the old interpretation of sync should be correct, but less optimal,
assuming OpenPower got their backwards compatibility correct.

4 months agobug 1251: WIP stbcx removed
Luke Kenneth Casson Leighton [Sun, 14 Jan 2024 19:36:18 +0000 (19:36 +0000)]
bug 1251: WIP stbcx removed

4 months agofix memory locations in linked-list test_caller_svp64_ldst.py
Luke Kenneth Casson Leighton [Mon, 8 Jan 2024 13:53:39 +0000 (13:53 +0000)]
fix memory locations in linked-list test_caller_svp64_ldst.py

4 months agofptrans.mdwn: don't parenthesize register being assigned to
Jacob Lifshay [Tue, 9 Jan 2024 08:01:44 +0000 (00:01 -0800)]
fptrans.mdwn: don't parenthesize register being assigned to

Fixes: https://bugs.libre-soc.org/show_bug.cgi?id=1247