Search Unity

4.6 iOS 64-bit beta

Discussion in 'iOS and tvOS' started by jonas-echterhoff, Jan 12, 2015.

  1. fertigo

    fertigo

    Joined:
    Feb 15, 2014
    Posts:
    19
    Just a short positive note between all errors and bugs;) I just built our coloring page / drawing app on 4.6.1p5 and all seems to run fine on iOS arm-64. Including Vectrosity and Ultimate-Mobile plugins (at least the parts we use)

    Keep up the good work Unity!
     
  2. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    @FredDeschenes

    Thanks, we will have a look at the bug you submitted.
     
  3. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    @fertigo

    Thanks for the positive report, it is always good to hear that things are working!
     
  4. Simie

    Simie

    Joined:
    Oct 26, 2012
    Posts:
    456
    I'm getting errors with GetCustomAttribute() when using IL2CPP. Somebody posted something similar on the last page, is this issue resolved?

    My stack trace:

    Code (CSharp):
    1. #0    0x00000001007d2470 in il2cpp::vm::Reflection::GetCustomAttributesCacheFor(TypeInfo*) [inlined] at /Users/builduser/buildslave/unity/build/Tools/il2cpp/il2cpp/libil2cpp/vm/Reflection.cpp:434
    2. #1    0x00000001007d2470 in il2cpp::vm::Reflection::GetCustomAttrsInfo(Il2CppObject*) at /Users/builduser/buildslave/unity/build/Tools/il2cpp/il2cpp/libil2cpp/vm/Reflection.cpp:489
    3. #2    0x00000001007a9e68 in il2cpp::icalls::mscorlib::System::MonoCustomAttrs::GetCustomAttributesInternal(Il2CppObject*, Il2CppReflectionType*, bool) at /Users/builduser/buildslave/unity/build/Tools/il2cpp/il2cpp/libil2cpp/icalls/mscorlib/System/MonoCustomAttrs.cpp:27
    4. #3    0x0000000100ae97c0 in mscorlib_System_MonoCustomAttrs_m_GetCustomAttributesInternal(mscorlib_System_Object*, mscorlib_System_Object*, mscorlib_System_Type*, bool) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_mscorlib_5.cpp:43251
    5. #4    0x0000000100ae9de8 in mscorlib_System_MonoCustomAttrs_m_GetCustomAttributesBase(mscorlib_System_Object*, mscorlib_System_Object*, mscorlib_System_Type*) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_mscorlib_5.cpp:43413
    6. #5    0x0000000100aea2c0 in mscorlib_System_MonoCustomAttrs_m_GetCustomAttributes_mscorlib_System_Object_arr1_mscorlib_System_Reflection_ICustomAttributeProvider_mscorlib_System_Type_mscorlib_System_Boolean(mscorlib_System_Object*, mscorlib_System_Object*, mscorlib_System_Type*, bool) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_mscorlib_5.cpp:43550
    7. #6    0x0000000100ae9fa0 in mscorlib_System_MonoCustomAttrs_m_GetCustomAttribute(mscorlib_System_Object*, mscorlib_System_Object*, mscorlib_System_Type*, bool) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_mscorlib_5.cpp:43452
    8. #7    0x00000001009e4810 in mscorlib_System_Attribute_m_GetCustomAttribute_mscorlib_System_Attribute_mscorlib_System_Reflection_MemberInfo_mscorlib_System_Type_mscorlib_System_Boolean(mscorlib_System_Object*, mscorlib_System_Reflection_MemberInfo*, mscorlib_System_Type*, bool) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_mscorlib_0.cpp:1461
    9. #8    0x00000001009e4778 in mscorlib_System_Attribute_m_GetCustomAttribute_mscorlib_System_Attribute_mscorlib_System_Reflection_MemberInfo_mscorlib_System_Type(mscorlib_System_Object*, mscorlib_System_Reflection_MemberInfo*, mscorlib_System_Type*) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_mscorlib_0.cpp:1451
    10. #9    0x0000000100812dd0 in AssemblyU002DCSharp_SRF_Service_SRServiceManager_m_UpdateStubs(AssemblyU002DCSharp_SRF_Service_SRServiceManager*) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_Assembly-CSharp_2.cpp:4798
    11. #10    0x0000000100811b78 in AssemblyU002DCSharp_SRF_Service_SRServiceManager_m_AutoCreateService(AssemblyU002DCSharp_SRF_Service_SRServiceManager*, mscorlib_System_Type*) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_Assembly-CSharp_2.cpp:4948
    12. #11    0x0000000100811850 in AssemblyU002DCSharp_SRF_Service_SRServiceManager_m_GetServiceInternal(mscorlib_System_Object*, mscorlib_System_Type*) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_Assembly-CSharp_2.cpp:4434
    13. #12    0x000000010013a110 in AssemblyU002DCSharp_SRF_Service_SRServiceManager_m_GetService_mscorlib_System_Object_mgp0_gshared(mscorlib_System_Object*, void**) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/GenericMethods0.cpp:25752
    14. #13    0x00000001007e7a78 in AssemblyU002DCSharp_SRF_Service_SRServiceManager_m_GetService_AssemblyU002DCSharp_SRDebugger_Services_IDebugService_mgp0(mscorlib_System_Object*) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_Assembly-CSharp_0.cpp:18832
    15. #14    0x00000001007e7b70 in AssemblyU002DCSharp_SRDebugger_SRDebuggerInit_m_Awake(AssemblyU002DCSharp_SRDebugger_SRDebuggerInit*) at /Users/simon/srdebuggersample/Build/iOS/Classes/Native/Bulk_Assembly-CSharp_0.cpp:19054
    16.  
     
  5. Lucas-Meijer

    Lucas-Meijer

    Unity Technologies

    Joined:
    Nov 26, 2012
    Posts:
    175
    @Simie, we'd love to take a look at your project and figure out what is going on. any chance you could file a bugreport on it? (Help->Report bug, it will offer to include your project)
     
  6. Simie

    Simie

    Joined:
    Oct 26, 2012
    Posts:
    456
    @ljmeijer, I've sent a bug report with my project attached (it's a WIP asset I'm working on for the asset store). The problem is similar to the last user who reported. I'm scanning the assembly for classes and methods tagged with attributes in my custom service manager. I've included a few details in the bug report. I haven't received an email with the bug# yet, but I'll edit this post with the # once I get it.

    EDIT:

    Case number is 666206
     
    Last edited: Jan 24, 2015
  7. drawcode

    drawcode

    Joined:
    Jul 21, 2008
    Posts:
    72
    With 4.6.1 pt5 release still getting linking errors on MethodInfo reflection for inherited classes. (see last screenshot).

    Similarly, on Unity 5 beta builds I am also getting compile errors in MethodInfo areas (see screenshot with slot error). Not sure if these are related and just showing differently on the different versions (one in linking, one in compile for MethodInfo using IL2CPP).

    The Unity 5 error is that the generation it blowing out the uint_8 above 255 for /* slot */ on the signatures.

    Note: I have had to increase ntrampolines higher on this project type as it gets errors on ios device of running out of trampolines and ntrampolines=1024 was the setting.

    IL2CPP
    Strip Byte Code
    Fast but no Exceptions

    See attached screenshot of configs.
     

    Attached Files:

  8. Allright

    Allright

    Joined:
    Sep 16, 2012
    Posts:
    2

    I ran into same problem in Unity 4.6.1p5 using IL2CPP

    Register_UnityEngine_NetworkPlayer_Internal_GetPlayerIndex()", referenced from:
    RegisterAllStrippedInternalCalls() in UnityICallRegistration.o

    But we are not using UnityEngine.Networking. It there anything else could be related?
     
  9. RalphH

    RalphH

    Administrator

    Joined:
    Dec 22, 2011
    Posts:
    592
    Without using networking, that sounds a bit strange. Mind to file a bug ?
     
  10. RalphH

    RalphH

    Administrator

    Joined:
    Dec 22, 2011
    Posts:
    592
    Hi, I'm pretty sure that both are resolved, but to make sure, can you please send us a bug report with the project so we can make sure that's the case. As for the vtable slots; that's been resolved for a little while already; unfortunately beta's will always lag behind a bit of what we already have in our development branches; expect this to be resolved in the next beta.
     
    drawcode likes this.
  11. MaydayWorks

    MaydayWorks

    Joined:
    Aug 18, 2014
    Posts:
    6
    I'm working with 4.6.1p5.
    Our project is heavily depending on uLua plugin, and with mono everything are right. With IL2CPP, we got "
    ArgumentException: Object contains non-primitive or non-blittable data." after app launched.
    the C# code is
    Code (CSharp):
    1. GCHandlehandle = GCHandle.Alloc(translator, GCHandleType.Pinned);
    2. IntPtrthisptr = GCHandle.ToIntPtr(handle);
    3. LuaDLL.lua_pushlightuserdata(L, thisptr);
    4. LuaDLL.lua_setglobal(L, "_translator");
    the console output:


    Will GCHandle.Alloc() be support in future release? Or is there a alter way to send a managed object to native dll? thanks
     
  12. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,680
    GCHandle.Alloc() is supported, but will throw an exception if you're trying to pin something that isn't 'pinnable'. What's inside "translator" variable? I believe Mono incorrectly didn't throw in this case, but it incurred undefined behaviour.
     
  13. joncham

    joncham

    Unity Technologies

    Joined:
    Dec 1, 2011
    Posts:
    276
    We do support GC handles. Don't allocate a pinned handle.

    Code (CSharp):
    1. GCHandle handle = GCHandle.Alloc(translator);
    Pinning is only if you need the object to not be moved, and that has additional restrictions; these restrictions are what the exception is about. We raise this exception to match .Net behavior IIRC.
     
  14. Umai

    Umai

    Joined:
    Jun 18, 2013
    Posts:
    74
    With 4.6.1p5 I suddenly get lots of linker errors like this, so can't build at all:

    duplicate symbol _adler32 in:

    iosbuilds/il2cpp461p5/Libraries/libiPhone-lib.a(adler32.o)

    duplicate symbol _crc32 in:

    iosbuilds/il2cpp461p5/Libraries/libiPhone-lib.a(crc32.o)

    duplicate symbol _deflateInit2_ in:

    iosbuilds/il2cpp461p5/Libraries/libiPhone-lib.a(deflate.o)

    duplicate symbol _deflateReset in:

    iosbuilds/il2cpp461p5/Libraries/libiPhone-lib.a(deflate.o)
     
  15. ZimM

    ZimM

    Joined:
    Dec 24, 2012
    Posts:
    963
    There seems to be some kind of issue with network sockets with IL2CPP.
    I have a simple TCP server that responds to any client by sending a text message and immediately closing the connection. There is also a TCP client that connects to that server, receives the message, and displays it when server closes the connection. It works fine with Mono runtime, but the client seems to block indefinitely in System.Net.Sockets.Socket.Receive instead of returning when new data arrives.

    I've sent a bug report with a simple scene that reproduces the bug, case number 666462.

    Thanks,
    Serhii.
     
  16. drawcode

    drawcode

    Joined:
    Jul 21, 2008
    Posts:
    72
    Thanks Ralph, we'll try to get a bug version up but the project is huge 8GB. I'lll try to get it down to just the problem. If no time, we'll definitely check on the next beta build if not as soon as it drops. You're doing good work, take a vacation after it all ships.

    Future Awesome for Bug Reporting from Cloud Builds

    For future awesome, and this is for QA/R&D, you could hook up bug reporting to cloud builds.

    We use cloud build for these builds (but not yet with IL2CPP). In the future, it would be awesome to just report a bug, point it to a cloud build and or repo version that the cloud build worker has access to. Then it just autonomously runs that and prepares it for developers, and any error reports.

    A killer feature of cloud beta testing could be auto running major updates like IL2CPP/OS updates/Mono updates to automated builds on cloud build. I am sure tons of people would opt-in to allow builds of their games/apps to be automatically checked by the Unity future builder bots and it would give Unity awesome information on how building/linking is affected with major updates for all platforms. This would make delivery of the projects very easy and effortless while being a cool feature of unity cloud build.
     
    Last edited: Jan 24, 2015
  17. joncham

    joncham

    Unity Technologies

    Joined:
    Dec 1, 2011
    Posts:
    276
    We are making use of zlib within the il2cpp runtime and the symbol names are conflicting with another copy of zlib being linked. Perhaps in another static library you are linking? This is being fixed for a future release.
     
    liortal likes this.
  18. Umai

    Umai

    Joined:
    Jun 18, 2013
    Posts:
    74
    We are using a couple of 3rd party ad network libraries - it's likely one of them uses zlib.

    I just tried a plain new 2D project with just one Canvas and Text label, it built and launched on device but did not display the Text label. I reported this bug (Case 666495). Output in Xcode log:

     
  19. Drowning-Monkeys

    Drowning-Monkeys

    Joined:
    Mar 6, 2013
    Posts:
    328
    Hi guys,

    First off - thanks so much for getting this build out. I am seeing some great performance gains from what i got working so far.

    Second. I am having a few issues:
    1. iTween has a lot of issues in x64 mode. Was wondering if anyone is noticing this. Specifically for me iTween.LookUpdate()
    2. I cannot compile a universal build w/ prime31 (But I CAN compile either an Arm7 or Arm64). I am using GameCenter and StoreKit, and they generate a lot of linker errors. I have tried completely removing and re-adding them, but so far no luck. attached is a screenshot of a few of the errors.

     
  20. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    @Umai
    We'vej ust seen this in another case. We're also considering using a prefix for zlib functions so that we can avoid a conflict like this. This change will likely ship in the next release.
     
  21. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    @ZimM

    We're looking at some other networking issue now. We will investigate this project as well, thanks for submitting it.
     
  22. JoshPeterson

    JoshPeterson

    Unity Technologies

    Joined:
    Jul 21, 2014
    Posts:
    6,938
    @Drowning Monkeys

    You may want to be sure that you have a version of Prime 31 which will work with IL2CPP. It looks like the libP31MonoBridge.a static library is still using the mono_ API, which won't work with IL2CPP. Maybe the wrong static library is being used here?
     
  23. Frederic-My

    Frederic-My

    Joined:
    Sep 23, 2012
    Posts:
    27
    I built my game with 4.6.1p5 and IL2CPP this afternoon, and played it for quite a while. So far:

    I ran into the "b/bl/blx ARM branch out of range" problem when linking, which I did not have before. Fortunately, that was in debug only, the release build still links.

    I didn't notice any lag this time, it looks like the garbage collection fix works for me. Yeah! :)
     
  24. Drowning-Monkeys

    Drowning-Monkeys

    Joined:
    Mar 6, 2013
    Posts:
    328
    I posted to their support site so hopefully i'll hear something soon. Sadly I am definitely on the latest version of the plugins :-(

    After reinstalling i get a slightly different error:
    ld: b/bl/blx thumb2 branch out of range (19895212 max is +/-16MB): from __Z34dictionaryWithOnlyValidJsonObjectsP12NSDictionary (0x00B20280) to ___stack_chk_fail@0x00000000 (0x01E198B8) in '__Z34dictionaryWithOnlyValidJsonObjectsP12NSDictionary' from /Users/Chud/Documents/Unity/DTSQ_NewEZGUI/Assets/Editor/Prime31Shared/libP31SharedTools.a(P31SharedTools.o) for architecture armv7 clang: error: linker command failed with exit code 1 (use -v to see invocation)
     
  25. taecg

    taecg

    Joined:
    Jun 14, 2014
    Posts:
    26
    In unity4.6.1.p3 using UnityEngine.SocialPlatforms to implement GameCenter in my list, compiled with mono when there is no problem, but when I switched to IL2CPP export, in the Xcode compiler to machine operation is out of the question:

    CubeParty`il2cpp:: vm:: Method:: GetParamCount (MethodInfo*) at Method.cpp:47:

    0x1008935f4: ldrb W0, [x0, #61]

    0x1008935f8: ret
     
  26. Funny-Face

    Funny-Face

    Joined:
    Nov 6, 2013
    Posts:
    17
    Hi,
    We've managed build our project somehow with Unity 4.6.1p5. which is good. But during runtime we have problems with third party native library for networking: PUN+ which provides their own sockets.

    it's generate a lot of exceptions during connection phase like this:

    SynchronizationLockException: Object has not been locked by this thread.
    at ExitGames.Client.Photon.PhotonPeer.SendOutgoingCommands () [0x00000] in <filename unknown>:0
    at PhotonHandler.Update () [0x00000] in <filename unknown>:0
    (Filename: currently not available on il2cpp Line: 4294967295)

    and

    Receive issue. State: Connected Exception: System.Threading.SynchronizationLockException: Object has not been locked by this thread.
    at System.Threading.Monitor.Exit (System.Object obj) [0x00000] in <filename unknown>:0
    at ExitGames.Client.Photon.SocketUdpNativeStatic.ReceiveLoop () [0x00000] in <filename unknown>:0
    at System.Threading.ThreadStart.Invoke () [0x00000] in <filename unknown>:0
    UnityEngine.Debug:Internal_Log(Int32, String, Object)
    UnityEngine.Debug:LogError(Object)
    PhotonHandler:DebugReturn(DebugLevel, String)
    NetworkingPeer:DebugReturn(DebugLevel, String)
    ExitGames.Client.Photon.<>c__DisplayClass2:<EnqueueDebugReturn>b__0()
    ExitGames.Client.Photon.MyAction:Invoke()
    ExitGames.Client.Photon.EnetPeer:DispatchIncomingCommands()
    ExitGames.Client.Photon.PhotonPeer:DispatchIncomingCommands()
    PhotonHandler:Update()

    (Filename: /Users/builduser/buildslave/unity/build/artifacts/iPhonePlayer-armv7-il2cppGenerated/UnityEngineDebug.cpp Line: 56)
    ExceptionOnReceive while connecting to: ns.exitgamescloud.com:5058. Check if the server is available.
    UnityEngine.Debug:Internal_Log(Int32, String, Object)
    UnityEngine.Debug:LogWarning(Object)
    NetworkingPeer:OnStatusChanged(StatusCode)
    ExitGames.Client.Photon.<>c__DisplayClass6:<EnqueueStatusCallback>b__4()
    ExitGames.Client.Photon.MyAction:Invoke()
    ExitGames.Client.Photon.EnetPeer:DispatchIncomingCommands()
    ExitGames.Client.Photon.PhotonPeer:DispatchIncomingCommands()
    PhotonHandler:Update()

    (Filename: /Users/builduser/buildslave/unity/build/artifacts/iPhonePlayer-armv7-il2cppGenerated/UnityEngineDebug.cpp Line: 56)

    Any suggestions what should we do? (Build works perfectly well with mono 2.x backend)
     
  27. manny003

    manny003

    Joined:
    Mar 18, 2014
    Posts:
    70
    I have been using the serialize/deserialize method to save complex game state and has been working flawlessly.

    However, when building for IL2CPP, I get the following error in Xcode when I'm trying to read back in saved serialized data:

    SerializationException: Could not find type 'System.Collections.Generic.List`1[[clsBoardSetInfo2, Assembly-UnityScript, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]'.
    at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadType (System.IO.BinaryReader reader, TypeTag code) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadTypeMetadata (System.IO.BinaryReader reader, Boolean isRuntimeObject, Boolean hasTypeInfo) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadObjectInstance (System.IO.BinaryReader reader, Boolean isRuntimeObject, Boolean hasTypeInfo, Int64& objectId, System.Object& value, System.Runtime.Serialization.SerializationInfo& info) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadObject (BinaryElement element, System.IO.BinaryReader reader, Int64& objectId, System.Object& value, System.Runtime.Serialization.SerializationInfo& info) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadObject (BinaryElement element, System.IO.BinaryReader reader, Int64& objectId, System.Object& value, System.Runtime.Serialization.SerializationInfo& info) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadNextObject (BinaryElement element, System.IO.BinaryReader reader) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadObjectGraph (BinaryElement elem, System.IO.BinaryReader reader, Boolean readHeaders, System.Object& result, System.Runtime.Remoting.Messaging.Header[]& headers) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.NoCheckDeserialize (System.IO.Stream serializationStream, System.Runtime.Remoting.Messaging.HeaderHandler handler) [0x00000] in <filename unknown>:0
    at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize (System.IO.Stream serializationStream) [0x00000] in <filename unknown>:0
    at GlobalData.readPlayerStats () [0x00000] in <filename unknown>:0
    at GlobalData.Start () [0x00000] in <filename unknown>:0
    (Filename: currently not available on il2cpp Line: 4294967295)


    Most of my programing is done using UnityScript/Javascript if that makes any difference.


    Here is the code portion where I am saving my game data:

    functionwritePlayerStats() {
    varfileName : String = Application.persistentDataPath + "/" + PLAYER_STATS_FILE_NAME;
    varformatter = newSystem.Runtime.Serialization.Formatters.Binary.BinaryFormatter();
    varfileStream : FileStream = File.Open(fileName, FileMode.Create);
    // serializedirectlyintothatstream.
    formatter.Serialize(fileStream, playerStats);

    fileStream.Close();
    }


    And here is the code portion where I am reading it back in:

    function readPlayerStats(playerStats : clsPlayerStats) {
    var formatter = new System.Runtime.Serialization.Formatters.Binary.BinaryFormatter();
    var fileStream : FileStream = File.OpenRead(fileName);

    playerStats = formatter.Deserialize(fileStream);
    fileStream.Close();
    }


    Also, way back in the beginning, I had to add this little line to make it all work:

    Environment.SetEnvironmentVariable("MONO_REFLECTION_SERIALIZER", "yes");

    UPDATE: I deleted the MONO_REFLECTION_SERIALIZER set environment line above and did NOT fix the issue.

    Any thoughts?

    Manny
     
    Last edited: Jan 25, 2015
  28. manny003

    manny003

    Joined:
    Mar 18, 2014
    Posts:
    70
    Just to add that i am also experiencing issues with Lerp. I'm using the Mathf.Lerp function to fade the alpha of an object and checking for when it reaches a desired value before continuing on -- but it never seems to reach that value.. just waits forever.

    UPDATE: I added some Debug.Log output and I can confirm that the Lerp does work to change the values; and that it does reach the desired value I'm looking for. HOWEVER, the IF statement I have to check for value 0.01f does not work -- even though the Debug output proves that that is the value (there is some looping logic that I have omitted but the value it is checking does indeed occur as this works in Mono):

    pnlDark.color.a = Mathf.Lerp(0.8f, 0.1f, (Time.time - tempTime2) * 4);

    Debug.Log("Value: " + pnlDark.color.a); // outputs 0.1

    if (pnlDark.color.a == 0.1f) {
    // supposed to do something here but never reaches code in IL2CPP
    }
     
    Last edited: Jan 25, 2015
  29. Agent_007

    Agent_007

    Joined:
    Dec 18, 2011
    Posts:
    899
  30. Lucas-Meijer

    Lucas-Meijer

    Unity Technologies

    Joined:
    Nov 26, 2012
    Posts:
    175
    @many0003: we have a fix for the serialization BinaryFormatter, that should land into next build.
    @Funny Face: we'd love to take a look at that project. initial guess looks like it's hitting something in our System.Threading.Monitor implementation.
    @taecg: that error has il2cpp bug written all over it, we would really really like to get a project that causes that crash to happen. (dont bother trying to strip it down too much, for crashbugs like that a smaller project doesn't help all that much)
    @Drowning Monkeys: next build should make that error go away. in the meantime, it is very likely that if you set xcode to release, it will build fine.
     
  31. Catacomber

    Catacomber

    Joined:
    Sep 22, 2009
    Posts:
    682
    I just installed the patch and changed the backend to IL2CPP in Player Settings and my project builds with about 140 warnings and it launches but then closes and dies. I see this message in the Xcode console---

    Unable to find type [UnityEngine.dll]UnityEngine.ResourceRequest

    I saw someone else had this problem a few pages back but reading through I don't see any solution. Any help in fixing this would be most appreciated. Do I have to take the old version of Unity out and run the patch?

    I don't use third party plugins except the Ork Framework.
     
    Last edited: Jan 25, 2015
  32. SpaceSimulator

    SpaceSimulator

    Joined:
    Jul 21, 2014
    Posts:
    11
    It seems as if IL2CPP doesnt cope well with "using" and IDisposable . is crashing in the weirdest ways...

    also , selecting "universal" and then tapping "Build * Run" ends up with a "unsupported CPU" error in Xcode. Not big deal, as the main issue here is getting the code compiling with IL2CPP . This is driving me real mad.

    ---------------------------------- edit- ------------------------------------

    Also , StringComparer class seems not implemented .

    https://msdn.microsoft.com/en-us/li...rer.invariantcultureignorecase(v=vs.110).aspx

    so is firing up a exception when creating a dictionary<string,sting >( stringcomparer.invariantcultureignorecase ) ;
     
    Last edited: Jan 26, 2015
  33. joncham

    joncham

    Unity Technologies

    Joined:
    Dec 1, 2011
    Posts:
    276
     
  34. joncham

    joncham

    Unity Technologies

    Joined:
    Dec 1, 2011
    Posts:
    276
    @SpaceSimulator we recently fixed a bug related to "using" keyword and IDisposable. I am not sure if it made it in the most recent beta. Filing a bug is the easiest way for us to track down the issues you are encountering.
     
    SpaceSimulator likes this.
  35. manny003

    manny003

    Joined:
    Mar 18, 2014
    Posts:
    70
    This is great news. Also, when I issue my app update in 64bit , would the be able to read and desereialize data save from a previous 32 bit version? This is on iOS. Would not be surprised of this were not possible since the word length would be twice as long -- I have no knowledge of how all this works internally -- but hoping Unity can work some magic.

    Manny
     
  36. manny003

    manny003

    Joined:
    Mar 18, 2014
    Posts:
    70
  37. FrenzooInfo

    FrenzooInfo

    Joined:
    May 2, 2014
    Posts:
    46
    I am also having the same problem as @Umai as I am creating a collection of small test cases to highlight different problems. This is a blocker for testing the latest patch release for us. Any idea of a workaround or a quick patch release?
     
  38. FrenzooInfo

    FrenzooInfo

    Joined:
    May 2, 2014
    Posts:
    46
    I can confirm that the weird array.reverse bug is fixed!! Yay..
     
  39. C2tP

    C2tP

    Joined:
    Jan 22, 2013
    Posts:
    4
    Thanks for all the updates guys. Before p5 I was having various linker issues but now for the most part i can get past them. However, now I'm getting the following error. Is there something I can do to resolve this?

    ld: b/bl/blx thumb2 branch out of range (25886892 max is +/-16MB): from _main (0x00009E9C) to _UIApplicationMain@0x00000000 (0x018BA040) in '_main' from /Users/clane/Library/Developer/Xcode/DerivedData/Unity-iPhone-gafdmnkjutpwqbgjbasbqfledyim/Build/Intermediates/Unity-iPhone.build/Debug-iphoneos/Unity-iPhone.build/Objects-normal/armv7/main.o for architecture armv7

    clang: error: linker command failed with exit code 1 (use -v to see invocation)



    Thank you for your help
     
  40. Catacomber

    Catacomber

    Joined:
    Sep 22, 2009
    Posts:
    682
    Thanks. Bug report # (Case 666808). Sent a stripped down version of the file---interestingly the stripped down version does load the main menu but you can't see it!

    The new message in the console is--(Am taking out repetitive lines)--

    2015-01-25 23:51:03.084 Omber[16929:2500142] -> registered mono modules 0xc9d0a0

    -> applicationDidFinishLaunching()

    -> applicationDidBecomeActive()

    Requesting Resolution: 768x1024

    Renderer: PowerVR SGX 543

    Vendor: Imagination Technologies

    Version: OpenGL ES 2.0 IMGSGX543-113.3

    GL_OES_depth_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_texture_float GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_vertex_array_object GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_label GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_draw_instanced GL_EXT_instanced_arrays GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_pvrtc_sRGB GL_EXT_read_format_bgra GL_EXT_separate_shader_objects GL_EXT_shader_framebuffer_fetch GL_EXT_shader_texture_lod GL_EXT_shadow_samplers GL_EXT_sRGB GL_EXT_texture_filter_anisotropic GL_EXT_texture_rg GL_EXT_texture_storage GL_APPLE_clip_distance GL_APPLE_color_buffer_packed_float GL_APPLE_copy_texture_levels GL_APPLE_framebuffer_multisample GL_APPLE_rgb_422 GL_APPLE_sync GL_APPLE_texture_format_BGRA8888 GL_APPLE_texture_max_level GL_APPLE_texture_packed_float GL_IMG_read_format GL_IMG_texture_comp

    ression_pvrtc

    Creating OpenGLES2.0 graphics device

    Initialize engine version: 4.6.1p5 (ea3e5beea19a)

    Mono Class HideInInspector couldn't be found! This might lead to random crashes later on!


    (Filename: Line: 114)


    Unable to find type [UnityEngine.dll]UnityEngine.ResourceRequest

    (Filename: Line: 1608)


    A script behaviour has a different serialization layout when loading. (Read 24 bytes but expected 44 bytes)

    Did you #ifdef UNITY_EDITOR a section of your serialized properties in any of your scripts?


    (Filename: Line: 1170)


    2015-01-25 23:51:09.874 Omber[16929:2500142] Received memory warning.

    WARNING -> applicationDidReceiveMemoryWarning()
     
    Last edited: Jan 26, 2015
  41. FrenzooInfo

    FrenzooInfo

    Joined:
    May 2, 2014
    Posts:
    46
    The initial Marshaling problem seems to have been fixed. However we are now getting EXC_BAD_ACCESS in the wrapper.

    Code (CSharp):
    1. // System.Boolean MeGirl.IO.Compression.TinyInflater.InflaterInputStream::FillBuffer_Callback(System.IntPtr,System.Int32,System.IntPtr,System.Int32&,System.Boolean&)
    2. int32_t STDCALL native_delegate_wrapper_AssemblyU002DCSharp_MeGirl_IO_Compression_TinyInflater_InflaterInputStream_m_FillBuffer_Callback(mscorlib_System_IntPtr inputBuffer, int32_t bytesToFill, mscorlib_System_IntPtr objectHandle, int32_t* bytesAvailable, int32_t* hasMore)
    3. {
    4.     // Marshaling of parameter 'inputBuffer' to managed representation
    5.  
    6.     // Marshaling of parameter 'bytesToFill' to managed representation
    7.  
    8.     // Marshaling of parameter 'objectHandle' to managed representation
    9.  
    10.     // Marshaling of parameter 'bytesAvailable' to managed representation
    11.     int32_t* _bytesAvailable_unmarshaled;
    12.     *_bytesAvailable_unmarshaled = *bytesAvailable;
    13.  
    14.     // Marshaling of parameter 'hasMore' to managed representation
    15.     bool* _hasMore_unmarshaled;
    16.     *_hasMore_unmarshaled = *hasMore;
    17.  
    18.     // Managed method invocation and marshaling of return value back from managed representation
    19.     bool _return_value = AssemblyU002DCSharp_MeGirl_IO_Compression_TinyInflater_InflaterInputStream_m_FillBuffer_Callback(NULL, inputBuffer, bytesToFill, objectHandle, _bytesAvailable_unmarshaled, _hasMore_unmarshaled);
    20.     return _return_value;
    21. }
    22.  
    Crashing at *_bytesAvailable_unmarshaled = *bytesAvailable
    the bytesAvailable ptr is valid and so are the contents. Obviously, the code generated is wrong as _bytesAvailable_unmarshaled is a invalid ptr.
     
  42. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,680
    @FrenzooInfo

    Could you submit a bug report with a method signature that causes it to generate this code (just so it doesn't get lost)?
     
    Last edited: Jan 26, 2015
  43. eddie312

    eddie312

    Joined:
    Sep 13, 2012
    Posts:
    24
    the p5 version fix the problem. thanks a lot
     
  44. FrenzooInfo

    FrenzooInfo

    Joined:
    May 2, 2014
    Posts:
    46
    Submitted:
    Case 666823
    ps. The code doesn't actually work, but the generated .cpp code should show the bug. The method signatures should be all there.
     
  45. Funny-Face

    Funny-Face

    Joined:
    Nov 6, 2013
    Posts:
    17
    @Funny Face: we'd love to take a look at that project. initial guess looks like it's hitting something in our System.Threading.Monitor implementation.

    Hi, we'll try to create smaller test build later to recreate the bug. But I suppose it will the same with just PUN+ demo project.
    http://u3d.as/content/exit-games/photon-pun-/5Ap
     
  46. FrenzooInfo

    FrenzooInfo

    Joined:
    May 2, 2014
    Posts:
    46
    It would be great if libjpeg is also given the same treatment as we are using libjpegturbo as an external library
     
  47. mh114

    mh114

    Joined:
    Nov 17, 2013
    Posts:
    295
    My game (well it's still a prototype) doesn't cause any crashes or errors but yet doesn't work correctly with the IL2CPP backend. I have just submitted a bug with a heavily stripped down project, hopefully you guys can figure it out what gets broken. Feel free to ask for details.

    Case number is 666848.
     
  48. Allright

    Allright

    Joined:
    Sep 16, 2012
    Posts:
    2
    Found out to be plugins calling. going to remove them.
    Thank you for reply.
     
  49. joncham

    joncham

    Unity Technologies

    Joined:
    Dec 1, 2011
    Posts:
    276
    Are you actually seeing issues with libjpeg? We don't make use of libjpeg in the il2cpp runtime, so I'd expect you would see the issue with mono backend as well?
     
  50. joncham

    joncham

    Unity Technologies

    Joined:
    Dec 1, 2011
    Posts:
    276
    @C2tP you can try finding the location in il2cpp-config.h where IL2CPP_METHOD_ATTR is defined, and define it to nothing.

    Code (csharp):
    1. #define IL2CPP_METHOD_ATTR
    This is an ARMv7 specific issue we are fixing in a future release.