Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (in practice, redundant operations are supposed to be trimmed)
- sub z:
- if !3d: error "cannot change z on non-3d vector"
- -realloc z
- sub y:
- if 1d: error "cannot change y on 1d vector"
- if 3d: free z in old y
- -realloc y
- sub x:
- if 3d: free z in y in old x
- if >=2d: free y in old x
- -realloc x
- add x:
- +realloc x
- if >=2d: malloc y in new x
- if 3d: malloc z in new y in new x
- add y:
- if 1d: error "cannot change y on 1d vector"
- +realloc y
- if 3d: malloc z in new y
- add z:
- if !3d: error "cannot change z on non-3d vector"
- +realloc z
- (priority is sub x,y,z then add x,y,z)
- _0x_0y_0z: (RETURN W/O ACTION)
- SUB
- _Nx_0y_0z: (atomic)
- sub x
- _0x_Ny_0z: (atomic)
- sub y
- _0x_0y_Nz: (atomic)
- sub z
- _Nx_Ny_0z: (_Nx_0y_0z,_0x_Ny_0z)
- sub x
- sub y
- _0x_Ny_Nz: (_0x_Ny_0z,_0x_0y_Nz)
- sub y
- sub z
- _Nx_0y_Nz: (_Nx_0y_0z,_0x_0y_Nz)
- sub x
- sub z
- _Nx_Ny_Nz: (_Nx_Ny_0z,_0x_0y_Nz)
- sub x
- sub y
- sub z
- ADD
- _Px_0y_0z: (atomic)
- add x
- _0x_Py_0z: (atomic)
- add y
- _0x_0y_Pz: (atomic)
- add z
- _Px_Py_0z: (_Px_0y_0z,_0x_Py_0z)
- add x
- add y
- _0x_Py_Pz: (_0x_Py_0z,_0x_0y_Pz)
- add y
- add z
- _Px_0y_Pz: (_Px_0y_0z,_0x_0y_Pz)
- add x
- add z
- _Px_Py_Pz: (_Px_Py_0z,_0x_0y_Pz)
- add x
- add y
- add z
- SUBX ADDYZ
- _Nx_Py_0z: (_Nx_0y_0z, _0x_Py_0z)
- sub x
- add y
- _Nx_0y_Pz: (_Nx_0y_0z, _0x_0y_Pz)
- sub x
- add z
- _Nx_Py_Pz: (_Nx_0y_0z, _0x_Py_Pz)
- sub x
- add y
- add z
- SUBY ADDXZ
- _Px_Ny_0z: (_0x_Ny_0z, _Px_0y_0z)
- sub y
- add x
- _0x_Ny_Pz: (_0x_Ny_0z, _0x_0y_Pz)
- sub y
- add z
- _Px_Ny_Pz: (_0x_Ny_0z, _Px_0y_Pz)
- sub y
- add x
- add z
- SUBZ ADDXY
- _Px_0y_Nz: (_0x_0y_Nz, _Px_0y_0z)
- sub z
- add x
- _0x_Py_Nz: (_0x_0y_Nz, _0x_Py_0z)
- sub z
- add y
- _Px_Py_Nz: (_0x_0y_Nz, _Px_Py_0z)
- sub z
- add x
- add y
- SUBXYZ ADDXYZ
- _Nx_Ny_Pz: (_Nx_Ny_0z, _0x_0y_Pz)
- sub x
- sub y
- add z
- _Px_Ny_Nz: (_0x_Ny_Nz, _Px_0y_0z)
- sub y
- sub z
- add x
- _Nx_Py_Nz: (_Nx_0y_Nz, _0x_Py_0z)
- sub x
- sub z
- add y
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement