Jump to content

billyb

Members
  • Content Count

    22
  • Joined

  • Last visited

Community Reputation

0 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. billyb

    debug IOS using instruments Leak detector

    Dalija, Thank you for the support. I tried to put a breakpoint on the Fend := nil; but it will not let me (shows x) I can put breakpoints on other code in my program. Not sure if this means anything... Module Load: CodeRouteTest. Has Debug Info. Base Address: $00000001043D8000. Process CodeRouteTest (1004) Module Load: dyld. No Debug Info. Base Address: $000000010A9AC000. Process CodeRouteTest (1004) I did try adding fend._release before fend.free and it crashes Exception Type: EXC_CRASH (SIGABRT) This is way outside my knowledge area. My program has lots of input text fields accross multiple form. Program runs for hrs before memory errors. Not sure where to go from here. But I will continue to review what you said and see if I can get a better understanding. Again thank you for you help. Bill B
  2. billyb

    debug IOS using instruments Leak detector

    Dalija, I have really no understanding of IOS Objective C so I am not in a postion to review the code. Any suggestions on Code changes in "Macapi.ObjectiveC" I am happy to try. Is this the code you are referring to? I see FObjectID created, but not free'd in the destroy event. Also the {$IFDEF AUTOREFCOUNT} is never used as both defined and not defined statments to release are commented out. constructor TOCLocal.Create; var CType: PTypeInfo; Reg: TRegisteredDelphiClass; begin inherited; CType := PTypeInfo(Self.ClassType.ClassInfo); Reg := TRegisteredDelphiClass.RegisterClass(CType, GetObjectiveCClass); FObjectID := Reg.CreateObj(Self); {$IFDEF DEBUGUTILS} TDebugUtils.DebugPrint('oc.local.create', 'Created instance of ''%s'' ObjID = 0x%x', [Self.ClassName, IntPtr(FObjectID)]); {$ENDIF} if FObjectID = nil then raise EObjectiveC.CreateResFmt(@SErrorCreatingOCObject, [CType^.NameFld.ToString]); end; destructor TOCLocal.Destroy; begin {$IFDEF DEBUGUTILS} TDebugUtils.DebugPrint('oc.local.destroy', 'Destroying instance of ''%s'' ObjID = 0x%x', [Self.ClassName, IntPtr(FObjectID)]); {$ENDIF} {$IFDEF AUTOREFCOUNT} // objc_msgSend(FObjectID, sel_registerName('release')); {$ELSE AUTOREFCOUNT} // objc_msgSend(FObjectID, sel_registerName('autorelease')); {$ENDIF AUTOREFCOUNT} inherited Destroy; end;
  3. billyb

    debug IOS using instruments Leak detector

    Dave, Your change made sense, I tried to look for other objects in a .destroy method that did not have a object.free. did not find any in fmx.platform.ios.pas that should be free'd I hate IOS.
  4. billyb

    debug IOS using instruments Leak detector

    Dave, I modified FMX.Platform.iOS, added it to my uses but it does not appear to make any difference in the leaks. program CodeRouteTest; uses System.StartUpCopy, {$IF Defined(IOS) and Defined(CPUARM)} IdSSLOpenSSLHeaders_Static, {$ELSE} IdSSLOpenSSLHeaders, {$ENDIF } {$IF Defined(IOS)} uMachExt in '..\..\..\BASE\MOBILE\Common\uMachExt.pas', {$ENDIF} FMX.PLATFORM.IOS IN 'FMX.PLATFORM.IOS.PAS', FMX.Forms, destructor TFMXTextRange.Destroy; begin FStart.free; // added by bb FEnd.free; // added by bb FStart := nil; FEnd := nil; inherited; end; I still get the TextRange errors as well as othe FMX errors Leaked Object Count Address Size Responsible Library Responsible Frame IFMXTextPosition 1 0x282c1fb70 16 Bytes CodeRouteTest 0x100829e08 UICTFontDescriptor 1 0x280a69200 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] UICTFontDescriptor 1 0x280b07a20 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 1 0x280a5d860 96 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 5 < multiple > 480 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] UICTFontDescriptor 1 0x2804671e0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 4 < multiple > 384 Bytes CodeRouteTest 0x1006ee21c Malloc 96 Bytes 1 0x280b27780 96 Bytes CodeRouteTest 0x1006ee21c Malloc 96 Bytes 3 < multiple > 288 Bytes CodeRouteTest 0x1006ee21c Malloc 96 Bytes 1 0x280a4a520 96 Bytes CodeRouteTest 0x1006ee21c Malloc 96 Bytes 1 0x280b17420 96 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 1 0x280a41800 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 1 0x280b272a0 96 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 1 0x280b1e8e0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 4 < multiple > 384 Bytes CodeRouteTest 0x1006ee21c Malloc 80 Bytes 1 0x280dabca0 80 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 2 < multiple > 192 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 3 < multiple > 288 Bytes CodeRouteTest 0x1006ee21c Malloc 96 Bytes 1 0x280ae0fc0 96 Bytes CodeRouteTest 0x1006ee21c Malloc 80 Bytes 3 < multiple > 240 Bytes CodeRouteTest 0x1006ee21c Malloc 80 Bytes 3 < multiple > 240 Bytes CodeRouteTest 0x1006ee21c Malloc 96 Bytes 1 0x280b535a0 96 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 1 0x28042a160 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 3 < multiple > 288 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 1 0x280ab8840 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] IFMXTextRange 3 < multiple > 48 Bytes CodeRouteTest 0x100829e08 UICTFontDescriptor 1 0x284a6e4c0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 4 < multiple > 384 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 1 0x280476f40 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] UICTFontDescriptor 5 < multiple > 480 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] UICTFontDescriptor 1 0x280440ae0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] UICTFontDescriptor 1 0x2804293e0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] UICTFontDescriptor 1 0x28045cea0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 1 0x280b52ca0 96 Bytes CodeRouteTest 0x1006ee21c Malloc 96 Bytes 5 < multiple > 480 Bytes CodeRouteTest 0x1006ee21c IFMXTextRange 1 0x282c1a140 16 Bytes CodeRouteTest 0x100829e08 Malloc 96 Bytes 3 < multiple > 288 Bytes CodeRouteTest 0x1006ee21c UICTFontDescriptor 3 < multiple > 288 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 96 Bytes 1 0x280aad4a0 96 Bytes CodeRouteTest 0x1006ee21c IFMXTextPosition 1 0x282c1a230 16 Bytes CodeRouteTest 0x100829e08 UICTFontDescriptor 1 0x28041a9a0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] IFMXTextPosition 1 0x282c05140 16 Bytes CodeRouteTest 0x100829e08 Malloc 96 Bytes 3 < multiple > 288 Bytes CodeRouteTest 0x1006ee21c
  5. Setup is delphi 10.4.2 - xcode 13 - sdk 15 I was finaly able to get instruments to work on my IOS app. (Had to build using developer cert and profile not adHoc) Where I run my app, with Leaks this is what I see for a short timestamp. My question is are all these leaks? How do I relate this to my code? In several cases, the program is just sitting on a screen waiting for user input, but the leak list keep growing. There are no timers in my program. Leaked Object Count Address Size Responsible Library Responsible Frame Malloc 96 Bytes 1 0x285eeaca0 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285f16460 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eeaee0 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eed5c0 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 3 < multiple > 288 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285f164c0 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285f67360 96 Bytes CodeRouteTest 0x100f1221c Malloc 80 Bytes 1 0x281d28500 80 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285f161c0 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 2 < multiple > 192 Bytes CodeRouteTest 0x100f1221c IFMXTextPosition 1 0x2839d6290 16 Bytes CodeRouteTest 0x10104de08 Malloc 96 Bytes 1 0x285f16b80 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285ee8ea0 96 Bytes CodeRouteTest 0x100f1221c IFMXTextPosition 1 0x2839d5c90 16 Bytes CodeRouteTest 0x10104de08 Malloc 96 Bytes 1 0x285f16580 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285ee94a0 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eeba20 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eeb000 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eef420 96 Bytes CodeRouteTest 0x100f1221c IFMXTextRange 1 0x2839d5170 16 Bytes CodeRouteTest 0x10104de08 Malloc 96 Bytes 1 0x285f66460 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eec420 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 2 < multiple > 192 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285ee9020 96 Bytes CodeRouteTest 0x100f1221c Malloc 80 Bytes 1 0x281d284b0 80 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285ee8a80 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eead00 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285ee2340 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eed680 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285eead60 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285f163a0 96 Bytes CodeRouteTest 0x100f1221c Malloc 96 Bytes 1 0x285f16ac0 96 Bytes CodeRouteTest 0x100f1221c UICTFontDescriptor 1 0x285f17ae0 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] UICTFontDescriptor 1 0x285ee5200 96 Bytes UIFoundation -[UIFontDescriptor _swapWithFontAttributes:options:] Malloc 80 Bytes 1 0x281d280f0 80 Bytes CodeRouteTest 0x100f1221c
  6. billyb

    IOS 15 suppoort

    Steve, this is not a component issue. this is the option to update local file cache when viewing the IOS sdk 14.5 Bill
  7. billyb

    IOS 15 suppoort

    OK, got it to compile, link and install my IOS Ipad app using Xcode 13.0 sdk 14.5 $(BDSPLATFORMSDKSDIR)\iPhoneOS14.5.sdk. App works correctly on IOS 14.8 and IOS 15. But when I tried to use "Update Local File Cache" option for the 14.5 SDK, I Get Directory does not exist: /Users/brianperconti/Desktop/Xcode 12.5.1.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/usr/include/ Makes me believe I am not using latest files from my mac. Also the Users/name is wrong (Matches to older mac that I used before) Bill
  8. billyb

    IOS 15 suppoort

    Should have asked before, Can update to Xcode 13 and sill use Delphi 10.4 or do I have to also update to Delphi 11? Bill
  9. billyb

    IOS 15 suppoort

    I do not seem to be able to locate xcode 12.5.1 to download when I login as Apple developer or the app store. Xcode 12.4 does not allow me to copy .IPA files to Ipad with IOS 15. Will I be able to copy IPA files if I upgrade to 12.5.1? I only have delphi 10.4 and not ready to update to delphi 11 (Too many 3rd party components) I saw several links in google but not apple site links for 12.5.1 any recomendations? Bill B
  10. billyb

    IOS 15 suppoort

    Dave, I just got an email saying that when the customer tried to run our program they got an error telling him it needs to be updated to be compatible. When I asked it program ran after the error message i was told no. I have no further info. I am upgrading one of my ipads to IOS 15 to see what happens and will post the results. My program runs fine on IOS 14.8 Let me know how it goes with your update. Thank you Bill B
  11. billyb

    IOS 15 suppoort

    One of my customers updated to IOS 15 and cannot run our FMX app. When I checked the embarcadero web site it shows only support to IOS 14. Is there a way to suport IOS 15. I am running delphi 10.4 update 2. Does the new version of Delphi 11 support IOS 15? Bill
  12. billyb

    Access violation on resume in IOS

    I do not have option to find error address, this is Delphi FMX IOS app. What is strange is that if I suspend to run another app and then resume (sometimes I get the access violation, othertimes I do not) There does not appear to be any code that is run when my app is resumed by IOS. I am re-compiling in debug mode to see if I get more information when it access violates
  13. billyb

    Access violation on resume in IOS

    I am getting nowhere with an issue I thought might be a memory leak, but afer added code to get Low Memory warning event message it is not the case. After using the Home button to suspend my app and run another IOS app and wait several minutes, if it return to my app and do anything I get a Access Viollation at address 00000001015C6BB0 accessing address 000000000000001A8. The does not happen every time, but often. I understand that this an error trying to reference a nill pointer, It happens when I try to click a button or show a dialog or edit a field on the form. If I do the same suspend, but do not wait a few minutes, there is no error. In one case I was able to pick a value from a dropdown list, but program locked up after selection of value, My program has no timers running. App uses SQLLite with TfdQuery and TFdmemtable Do I need to do anything on IOS events AAppevent.aeWillBecomeInactive AAppevent.aeEnteredBackground Any suggestions on how to proceed. I am running IOS 10.4.6 ipad 7 gen delphi 10.4.2 sdk 13.6
  14. billyb

    need code to receive low memory warning

    I have added the code and it works, thank you. Turns out I do not have a memory issue with the app. Bill B
  15. I have a delphi app that appears to be crashing due to low memory. How do I define a routine to capture any low memory warnings sent by IOS? My app is running on IOS 10.4.6 on a 7gen ipad.
×