Skip to content

Releases: theseus-rs/ristretto

v0.12.2

13 Dec 01:37
Compare
Choose a tag to compare

✨ Enhancements

  • optimize java.lang.Math and java.lang.StrictMath methods with Rust implementations (#181)

🐞 Bug fixes

  • implement java.lang.invoke.MethodHandleNatives.resolve(Ljava/lang/invoke/MemberName;Ljava/lang/Class;IZ)Ljava/lang/invoke/MemberName; (#194)
  • implement jdk.internal.misc.Unsafe.shouldBeInitialized0(Ljava/lang/Class;)Z (#193)
  • implement deep clone for java.lang.Object.clone() (#192)
  • implement java.lang.Class.isInstance(Ljava/lang/Object;)Z (#189)
  • implement java.lang.Class.getDeclaringClass0() (#188)
  • correct value returned from java.lang.Class.getName() (#187)
  • update class loading to support package.ClassName format for VM, Thread and ClassLoader (#183)
  • update java.lang.Class.getSimpleBinaryName0() to work with class objects (#186)
  • update java.lang.Class.getDeclaringClass0() to return null instead of void (#184)
  • update java.lang.Class.getEnclosingMethod0() to use the class file EnclosingMethod attribute per 4.7.7 (#185)
  • correct exception handling class check (#182)
  • implement java.lang.StrictMath (#180)

πŸ“¦ Build system

  • enable auditable, cyclonedx and github attestations (#197)
  • upgrade to cargo dist 0.26.1 (#196)
  • upgrade to cargo dist 0.26.0 and add new builds (#195)
  • conditionally register macos native functions (#191)
  • update serde and thiserror (#190)
  • update x86_64-apple-darwin release to use macos-13 (#179)

v0.12.1

06 Dec 23:09
Compare
Choose a tag to compare

🐞 Bug fixes

  • implement preview features flag (#178)
  • correct object array lengt allocation for java.lang.reflect.Array.newArray(Ljava/lang/Class;I)Ljava/lang/Object; (#177)
  • correct minimum value handling for ineg and lneg instructions (#176)
  • implement java.lang.ProcessHandleImpl.getCurrentPid0()J (#175)
  • correct exception handling by translating ranges to/from bytes/instructions (#172)
  • implement numerous jdk.internal.misc.Unsafe get<type>() and put<type>() methods (#171)
  • implement jdk.internal.misc.Unsafe.objectFieldOffset0(Ljava/lang/reflect/Field;)J (#170)
  • correct java.lang.Class.getDeclaredFields0(Z)[Ljava/lang/reflect/Field; to work with latest Java versions (#169)
  • add properties to jdk.internal.util.SystemProps$Raw.vmProperties()[Ljava/lang/String; (#168)
  • correct line number offsets (#167)
  • implement java.lang.String.intern()Ljava/lang/String; (#166)
  • implement java.util.concurrent.atomic.AtomicLong.VMSupportsCS8()Z (#165)
  • implement java.lang.Float.intBitsToFloat(I)F (#164)
  • implement java.lang.ClassLoader methods (#161)
  • correct getCallerClass() to return null instead of void (#159)

πŸ“– Documentation

  • update documentation links to point to latest jvm version (#174)

πŸ“¦ Build system

  • update dependencies (#158)

πŸ› οΈ Other improvements

  • improve todo docs (#163)
  • refactor native methods into a module hierarchy (#162)
  • add System.getSecurityManager() and System.setSecurityManager() implementations (#160)

v0.12.0

29 Nov 18:55
Compare
Choose a tag to compare

πŸ’₯ Breaking changes

  • create JavaError to convert Rust error to Java exceptions (#139)
  • rename Value.to_object() -> Value.to_reference(). remove Value.try_to_object(). add Reference::TryInto<Object>, Value::TryInto<Object>, and Value::TryInto<Reference>. (#135)

✨ Enhancements

  • add ClassPath.class_names() (#145)
  • optimize class equality check (#140)

🐞 Bug fixes

  • correct errors with Java 11 initialization (#154)
  • correct Java 8 string handling to encode Rust strings as UTF-16 (#153)
  • add Class.fields() and update Class.get_declared_fields_0() to use the class fields instead of the object fields (#152)
  • correct field initialization (#151)
  • correct FieldType.class_name() to handle object arrays and multi-arrays (#150)
  • implement java.lang.Class.getDeclaredFields0() and sun.misc.Unsafe.* methods (#149)
  • implement java.security.AccessController.doPrivileged() methods (#148)
  • stub native methods (#147)
  • update class names to support modules (#146)
  • add java.lang.invoke.MethodHandleNatives.registerNatives()V and jdk.internal.misc.PreviewFeatures.isPreviewEnabled()Z (#144)
  • correct Object.clone() to behave as a reference copy (#143)
  • set String.hashIsZero to false when creating a new string in Java 17+ (#141)
  • add java.lang.reflect.Array.newArray(Ljava/lang/Class;I)Ljava/lang/Object; (#137)
  • add BaseType.class_name() and FieldType.class_name() (#136)
  • rename Value.to_object() -> Value.to_reference(). remove Value.try_to_object(). add Reference::TryInto<Object>, Value::TryInto<Object>, and Value::TryInto<Reference>. (#135)
  • correct checkcast/instanceof instructions for Object[] (#134)
  • implement Java ArithmeticException for / by zero (#133)
  • add java.lang.Class.getModifiers()I and jdk.internal.reflect.Reflection.getClassAccessFlags(Ljava/lang/Class;)I (#132)

πŸ› οΈ Other improvements

  • update to Rust 1.83 (#155)
  • rename Arguments.[pop|push]_object() -> Arguments.[pop|push]_reference() (#142)
  • create JavaError to convert Rust error to Java exceptions (#139)
  • order object field debug output (#138)

v0.11.1

17 Nov 16:51
Compare
Choose a tag to compare

🐞 Bug fixes

  • add java.lang.Class.getComponentType()Ljava/lang/Class; for Java 8 (#130)
  • enable legacy Java system property initialization (#128)
  • initialize VM; call System.initPhase2() and System.initPhase3() (#127)
  • add jdk.internal.misc.Unsafe put<primitive> methods (#126)
  • add jdk.internal.misc.Unsafe.copyMemory0(Ljava/lang/Object;JLjava/lang/Object;JJ)V (#125)
  • add Class.componentType for array classes (#124)
  • correct implementation of jdk.internalmisc.Unsafe for int and long (#123)
  • add jdk.internal.misc.CDS.getCDSConfigStatus()I (#122)
  • add java.lang.Class.forName0(Ljava/lang/String;ZLjava/lang/ClassLoader;Ljava/lang/Class;)Ljava/lang/Class; and java.security.AccessController.getStackAccessControlContext()Ljava/security/AccessControlContext; (#121)
  • remove unnecessary thread creation for new objects (#119)

πŸ“¦ Build system

  • update dist to 0.25.1 (#131)

πŸ› οΈ Other improvements

  • update method registry to conditionally register methods based on java version (#129)
  • add primordial thread (#120)

v0.11.0

13 Nov 21:28
Compare
Choose a tag to compare

πŸ’₯ Breaking changes

  • refactor VM.load_class() -> Thread.class() and VM.new_object() -> VM.object() (#116)
  • implement TryInto for Value, Reference and Object (#105)

✨ Enhancements

  • add string support to RustValue (#115)
  • add VM.new_object() (#114)
  • update class loader to support primitive classes (#109)
  • add JavaObject trait (#106)
  • implement TryInto for Value, Reference and Object (#105)

🐞 Bug fixes

  • add Class.getDeclaringClass0()java/lang/Class, Class.getSigners()Ljava/lang/Object;, Class.isHidden()Z, Class.setSigners(Ljava/lang/Object;)V (#113)
  • add Class.getClassAccessFlagsRaw0()I, Class.getClassFileVersion0()I and Class.getPermittedSubclasses0()[Ljava/lang/Class; (#112)
  • add Class.isInterface()Z (#111)
  • update Unsafe.compareAndSetReference() to support Objects (#110)
  • implement jdk.internal.misc.VM.initializeFromArchive(Ljava/lang/Class;)V, jdk.internal.misc.Unsafe.addressSize0()I, jdk.internal.misc.Unsafe.isBigEndian0()Z, jdk.internal.misc.Unsafe.unalignedAccess0()Z (#104)
  • correct is_assignable_from, checkcast and instanceof array handling (#103)
  • add awt native initIDs() methods (#101)

πŸ› οΈ Other improvements

  • refactor invoke (#118)
  • delegate VM.object() -> Thread.object() (#117)
  • refactor VM.load_class() -> Thread.class() and VM.new_object() -> VM.object() (#116)
  • improve object debug output (#108)
  • update parent reference (#107)
  • remove explicit use of box pin (#102)

v0.10.1

01 Nov 05:25
Compare
Choose a tag to compare

✨ Enhancements

  • add environment variable support (#98)

🐞 Bug fixes

  • pass command line arguments as a string array to main methods (#97)
  • correct invokedynamic instruction debug logging (#96)
  • create array class for anewarray instruction (#95)
  • correct invokedynamic bytecode serialization (#93)

πŸ› οΈ Other improvements

  • simplify native method implementations (#94)
  • move additional logic into instruction functions (#92)
  • refactor VM internals for threading support (#91)

v0.10.0

21 Oct 18:15
Compare
Choose a tag to compare

πŸ’₯ Breaking changes

  • implement java.home system property (#80)

✨ Enhancements

  • implement multianewarray instruction (#89)
  • implement system properties (#82)
  • implement athrow instruction (#78)

🐞 Bug fixes

  • correct bug setting StackTraceElement.declaringClass (#90)
  • update cli to print stack trace when a throwable is returned from the vm (#88)
  • implement java.io.WinNTFileSystem.initIDs() (#87)
  • implement sun.nio.fs.UnixNativeDispatcher (#86)
  • implement java.io.UnixFileSystem.getBooleanAttributes0() (#85)
  • correct handling of finally blocks (#84)
  • implement jdk.internal.loader.NativeLibraries.findBuiltinLib() (#83)
  • implement java.home system property (#80)
  • correct invoke instruction error messages (#77)
  • correct exception table handler_pc offsets to/from instructions/bytes (#75)
  • remove unnecessary clone of method code (#71)

πŸ“¦ Build system

  • update to cargo-dist 0.23.0 (#81)
  • update corretto versions (#79)
  • update to Rust 1.82.0 (#73)

πŸ› οΈ Other improvements

  • update corretto versions (#79)
  • refactor default runtime version constant (#76)
  • rename CodeException to ExceptionTableEntry to better align with JVM specification naming (#74)
  • implement async Thread.sleep() and Thread.yield() (#72)
  • rename RuntimeError to InternalError (#70)

v0.9.0

15 Oct 16:26
Compare
Choose a tag to compare

πŸ’₯ Breaking changes

  • update vm to be async (#56)
  • rename VM.class() to VM.load_class() and VM.load() to VM.class() (#68)

✨ Enhancements

  • add stack size to frame debug logging (#65)
  • enable wasm32 builds (#61)
  • update vm to be async (#56)
  • implement Reflection.getCallerClass() (#55)
  • implement native method CDS.getRandomSeedForDumping()J (#48)
  • add support for invoking interface method ref (#47)

🐞 Bug fixes

  • stub implementation of java.lang.ref.Reflection.refersTo0() (#69)
  • correct invokeinterface instruction class resolution (#67)
  • increase windows stack size to 8MB (#66)
  • implement Class.getSuperclass() and Class.isAssignableFrom() (#64)
  • correct invokespecial instructions to only use methods from the class hierarchy (#63)
  • implement java.lang.Throwable.fillInStackTrace() (#62)
  • implement java.lang.System.mapLibraryName() (#60)
  • implement java.lang.System.identityHashCode() (#59)
  • implement java.io.UnixFileSystem.initIDs() (#58)
  • implement Class.is_array (#57)
  • corrected bug where lushr instruction was using incorrect mask (#50)
  • correct class interface loading and association (#49)

πŸ› οΈ Other improvements

  • rename VM.class() to VM.load_class() and VM.load() to VM.class() (#68)
  • update frame to have interior mutability (#54)
  • update Frame to reference CallStack (#53)
  • update CallStack to store reference to VM (#52)
  • update call stack to have interior mutability of frames (#51)

v0.8.1

11 Oct 19:16
Compare
Choose a tag to compare

🐞 Bug fixes

  • correct constant pool formatted string values (#45)
  • correct bipush to support negative values; return void from CDS.initializeFromArchive() (#44)

πŸ› οΈ Other improvements

  • remove unnecessary instanceof option check (#46)

v0.8.0

10 Oct 23:28
Compare
Choose a tag to compare

πŸ’₯ Breaking changes

  • initial vm (#43)
  • removed cycle between ClassLoader and Class (#34)
  • improve class loader interface (#33)

✨ Enhancements

  • initial vm (#43)
  • update lookupswitch instruction to use an IndexMap (#35)
  • improve class loader interface (#33)
  • add reserved impdep1 and impdep2 instructions (#32)

🐞 Bug fixes

  • removed cycle between ClassLoader and Class (#34)