I am building and running a simple Open MPI C application.
In order to run it, I configured the run process in this way:\
Edit Scheme -> Run -> Info -> Executable -> Other... -> /path/to/mpiexec
Edit Scheme -> Run -> Arguments -> Arguments Passed On Launch -> -np 4 "$(BUILT_PRODUCTS_DIR)/$(EXECUTABLE_NAME)"
Now, instead of the hardcoded "4" as the number of processes, I want to specify an environment variable (like the already existing BUILT_PRODUCTS_DIR and EXECUTABLE_NAME environment variables), so I enter in Environment Variables NUM_PROCS as Name and 4 as Value.
Thus, I write in Arguments Passed On Launch the whole quoted string:
"-np" "$(NUM_PROCS)" "$(BUILT_PRODUCTS_DIR)/$(EXECUTABLE_NAME)".
And Xcode can't read the NUM_PROCS environment variable (despite I can easily read it in the C program by a getenv("NUM_PROCS")!), in fact, it runs the default number of processes of my system (12).
I tried in a very large number the different ways of writing arguments (every string on a new line, with quotes, without quotes, ...), but none worked as I expected.
M3 Pro, macOS Sequoia 15.0.1
Xcode 16.0
Apple Silicon
RSS for tagBuild apps, libraries, frameworks, plug-ins, and other executable code that run natively on Apple silicon.
Posts under Apple Silicon tag
52 Posts
Sort by:
Post
Replies
Boosts
Views
Activity
hi
Question is in the title.. do we already know the length of the vectors?
best regards
Hi community!
It is known that application designed for iOS may be launched on MacOS with arm chip.
With XCode this is simple, you just choose to launch on current machine (Designed for iPad). As I can see, some magic happens: some tool wraps myproj.app into another app, which contains WrappedBundle link and Wrapper subdirectory.
Does anybody know how to invoke this wrapping tool via command line? I am using CLion as IDE for my personal preferences, and I want to build app with CLion and wrap the result with external tool into a MacOS-compatible app to test if it works for MacOS as well.
In other words, having the myproj.app I want to run something like "magictool -wrap /path/to/myproj.app"
Best regards!
I have an iOS/iPadOS app. When I run the app on Mac as a Designed for iPad app, Save button on the Share Sheet crashes the app.
I want to share a view with ImageRenderer, but here's an even easier example where I am trying to share an SF Symbol as an image.
ShareLink(item: Image(systemName: "swift"), preview: SharePreview(Text("PNG"), image: Image(systemName: "swift")))
Share button works. It opens Share Sheet. "Add to Photos" works. "Copy" works. I can paste the image file in Finder after I press "Copy". But when I press the "Save" button, my app crashes with the error:
Thread 1: "-[NSItemProvider pathExtension]: unrecognized selector sent to instance 0x600001c1e290"
How to fix this error? How to make saving the image work? Maybe I need additional permissions in plist? I already have "Privacy - Photo Library Additions Usage Description" and everything on iOS and iPadOS works without a problem.
Since I haven't heard so much as a peep from Apple on this, I thought I'd take a poll here on how long I could expect an easily reproducible (albeit possibly obscure) kernel panic to be fixed.
I was under the impression that kernel panics were a big deal but it's been almost 2 months since I updated from macOS 14 to macOS 15.0 dev beta 7 / public beta 5 when I originally came across and reported a panic triggered while playing StarCraft II.
I've been able to consistently trigger panics playing certain (maybe all) Co-op maps in SC2 and since my first report Aug 22, I've filed 8 additional bug reports, each automatically generated after hitting yet another panic. (I'm not sure exactly who is able to view these but for what it's worth, these are the reports I've filed so far: FB14886510, FB14905773, FB14960435, FB15304609, FB15391195, FB15467943, FB15468127, FB15491485, FB15491684.)
A few other people have reported the issue to SC2's developer, Blizzard, and apparently Blizzard has acknowledged they're aware of the problem so it's safe to rule out the possibility of a hardware defect or other issue specific only to my computer.
The logs point the blame at the AppleDCP driver, although I suppose the problem could technically be in the DCP firmware instead. Regardless, Apple's code is clearly at fault here.
I'll admit the importance of a video game isn't exactly like keeping the power on at a hospital but I don't know why it would be deemed particularly unimportant either.
At 53 days in, am I wrong to expect this to have been fixed by now or is Apple really being that slow?
I developed my app with React-Native-CLI, version 0.67.2.
I use Xcode 16 on MacOS Sequoia 15.0.1
It builds and runs fine on any simulator, iOS 17 or iOS 18. As soon as I build it for my iPhone 12 iOS 17.6.1 or archive, it throws this error "Command PhaseScriptExecution failed with a nonzero exit code" at the last time. It actually starts the Metro.
I made my iPhone into developer mode.
Paired it with MacOS.
The thing I don't get why it doesn't work on my iPhone when it works fine on simulators. It doesn't even archive.
Anyone encountered something like this in the past?
After building the app for TextFlight, I uploaded it.
After that, I initially received the following message via email.
"ITMS-90899: Macs with Apple silicon support issue - The app isn‘t compatible with the provided minimum macOS version of 11.0. It can run on macOS 12.0 or later. Please specify an LSMinimumSystemVersion value of 12.0 or later in a new build, or select a compatible version in App Store Connect."
So I added "LSMinimumSystemVersion" to info.plist, increased the version, and uploaded it again.
Next
"ITMS-90863: Macs with Apple silicon support issue - The app links with libraries that aren’t present in macOS:
/usr/lib/swift/libswiftCloudKit.dylib
@rpath/libswiftCloudKit.dylib"
I received an issue email like the above.
The app has supported Mac (Designed by iPad) so far.
This time, this issue occurs after building in Xcode 16.0 / MacBook OS 14.6.1.
The app being built supports at least iOS 14.
We cannot uncheck it because we must support "Mac (Designed by iPad)" in the future.
This issue did not occur in the initial upload and distribution.
It occurred after deleting all files in the ~/Library/Developer/Xcode/DerivedData path and rebuilding the project.
Is this an Xcode bug that will be fixed in the next update? Or is there a separate solution?
hello,
i wrote a method with Neon for accelerate my code..
I don't have the expected result
only simples instructions and, or, shift... on 64bits
no gain speed. nada :-(
i dont understand... how programm this method for speed?
original code :
unsigned long long RXBitBoard::get_legal_moves(const unsigned long long p_discs, const unsigned long long o_discs) {
const unsigned long long inner_o_discs = o_discs & 0x7E7E7E7E7E7E7E7EULL;
/* direction W */
unsigned long long
flipped = (p_discs >> 1) & inner_o_discs;
flipped |= (flipped >> 1) & inner_o_discs;
unsigned long long adjacent_o_discs = inner_o_discs & (inner_o_discs >> 1);
flipped |= (flipped >> 2) & adjacent_o_discs;
flipped |= (flipped >> 2) & adjacent_o_discs;
unsigned long long legals = flipped >> 1;
// /* direction _E*/
// flipped = (p_discs << 1) & inner_o_discs;
// flipped |= (flipped << 1) & inner_o_discs;
//
// adjacent_o_discs = inner_o_discs & (inner_o_discs << 1);
//
// flipped |= (flipped << 2) & adjacent_o_discs;
// flipped |= (flipped << 2) & adjacent_o_discs;
//
// legals |= flipped << 1;
// trick
/* direction _E */
flipped = (p_discs << 1);
legals |= ((flipped + inner_o_discs) & ~flipped);
/* direction S */
flipped = (p_discs >> 8) & o_discs;
flipped |= (flipped >> 8) & o_discs;
adjacent_o_discs = o_discs & (o_discs >> 8);
flipped |= (flipped >> 16) & adjacent_o_discs;
flipped |= (flipped >> 16) & adjacent_o_discs;
legals |= flipped >> 8;
/* direction N */
flipped = (p_discs << 8) & o_discs;
flipped |= (flipped << 8) & o_discs;
adjacent_o_discs = o_discs & (o_discs << 8);
flipped |= (flipped << 16) & adjacent_o_discs;
flipped |= (flipped << 16) & adjacent_o_discs;
legals |= flipped << 8;
/* direction NE */
flipped = (p_discs >> 7) & inner_o_discs;
flipped |= (flipped >> 7) & inner_o_discs;
adjacent_o_discs = inner_o_discs & (inner_o_discs >> 7);
flipped |= (flipped >> 14) & adjacent_o_discs;
flipped |= (flipped >> 14) & adjacent_o_discs;
legals |= flipped >> 7;
/* direction SW */
flipped = (p_discs << 7) & inner_o_discs;
flipped |= (flipped << 7) & inner_o_discs;
adjacent_o_discs = inner_o_discs & (inner_o_discs << 7);
flipped |= (flipped << 14) & adjacent_o_discs;
flipped |= (flipped << 14) & adjacent_o_discs;
legals |= flipped << 7;
/* direction NW */
flipped = (p_discs >> 9) & inner_o_discs;
flipped |= (flipped >> 9) & inner_o_discs;
adjacent_o_discs = inner_o_discs & (inner_o_discs >> 9);
flipped |= (flipped >> 18) & adjacent_o_discs;
flipped |= (flipped >> 18) & adjacent_o_discs;
legals |= flipped >> 9;
/* direction SE */
flipped = (p_discs << 9) & inner_o_discs;
flipped |= (flipped << 9) & inner_o_discs;
adjacent_o_discs = inner_o_discs & (inner_o_discs << 9);
flipped |= (flipped << 18) & adjacent_o_discs;
flipped |= (flipped << 18) & adjacent_o_discs;
legals |= flipped << 9;
//Removes existing discs
legals &= ~(p_discs | o_discs);
return legals;
}
my neon code
const uint64x2_t pp_discs = vdupq_n_u64(p_discs);
const uint64x2_t oo_discs = vdupq_n_u64(o_discs);
const uint64x2_t inner_oo_discs = vdupq_n_u64(o_discs & 0x7E7E7E7E7E7E7E7EULL);
//horizontals directions -1, +1
static const int64x2_t shift_1 = {-1, 1};
static const int64x2_t shift_2 = {-2, 2};
uint64x2_t
flipped = vandq_u64(vshlq_u64(pp_discs, shift_1), inner_oo_discs);
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_1), inner_oo_discs));
uint64x2_t
adjacent_oo_discs = vandq_u64(inner_oo_discs, vshlq_u64(inner_oo_discs, shift_1));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_2), adjacent_oo_discs));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_2), adjacent_oo_discs));
uint64x2_t legals = vshlq_u64(flipped, shift_1);
//verticals directions -8 , +8
static const int64x2_t shift_8 = {-8, 8};
static const int64x2_t shift_16 = {-16, 16};
flipped = vandq_u64(vshlq_u64(pp_discs, shift_8), oo_discs);
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_8), oo_discs));
adjacent_oo_discs = vandq_u64(oo_discs, vshlq_u64(oo_discs, shift_8));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_16), adjacent_oo_discs));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_16), adjacent_oo_discs));
legals = vorrq_u64(legals, vshlq_u64(flipped, shift_8));
//diagonals directions -7 , +7
static const int64x2_t shift_7 = {-7, 7};
static const int64x2_t shift_14 = {-14, 14};
flipped = vandq_u64(vshlq_u64(pp_discs, shift_7), inner_oo_discs);
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_7), inner_oo_discs));
adjacent_oo_discs = vandq_u64(inner_oo_discs, vshlq_u64(inner_oo_discs, shift_7));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_14), adjacent_oo_discs));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_14), adjacent_oo_discs));
legals = vorrq_u64(legals, vshlq_u64(flipped, shift_7));
//diagonals directions -9 , +9
static const int64x2_t shift_9 = {-9, 9};
static const int64x2_t shift_18 = {-18, 18};
flipped = vandq_u64(vshlq_u64(pp_discs, shift_9), inner_oo_discs);
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_9), inner_oo_discs));
adjacent_oo_discs = vandq_u64(inner_oo_discs, vshlq_u64(inner_oo_discs, shift_9));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_18), adjacent_oo_discs));
flipped = vorrq_u64(flipped, vandq_u64(vshlq_u64(flipped, shift_18), adjacent_oo_discs));
legals = vorrq_u64(legals, vshlq_u64(flipped, shift_9));
return ((vgetq_lane_u64(legals, 0) | vgetq_lane_u64(legals, 1)) & ~(p_discs | o_discs));
}
i even wrote a interleave version
I can expect a speed gain, no?
I have an Intel based Macbook Pro, which I use for iOS development.
Recently I have the need to test my apps on M-series Apple Silicon based simulator images (specifically, 13 inch versions of iPads) which have no "A" series equivalent (iPad Air 13, iPad Pro 13, etc).
I have "created" simulators for these devices in Xcode Simulators and Devices, but they do never appear under the File > Open Simulator menu.
I have confirmed that creating a new simulator with any A-class device does not exhibit this issue.
Interestingly, these device types do NOT appear under the same "Device Type" menu when attempting to create a "New Simulator" from within the Simulator itself.
Creating a Simulator in "Device and Simulators"
The same menu from inside the "Simulator" app - missing M-class devices:
Can anyone confirm, preferably with a link to the documentation, that this is intended behavior?
Apple expects us to support M class devices, on still-supported Intel devices, without access to appropriate simulators?
Or is this just my machine?
System:
16-inch, 2019 MacBook Pro
Sonoma 14.0
Xcode 15.4 (15F31d)
Thank you
Investigating a kernel panic, I discovered that Apple Silicon Panic traces are not working with how I know to symbolicate the panic information. I have not found proper documentation that corrects this situation.
Attached file is an indentity-removed panic, received from causing an intentional panic (dereferencing nullptr), so that I know what functions to expect in the call stack. This is cut-and-pasted from the "Report To Apple" dialog that appears after the reboot:
panic_1_4_21_b.txt
To start, I download and install the matching KDK (in this case KDK_14.6.1_23G93.kdk), identified from this line:
OS version: 23G93
Kernel version: Darwin Kernel Version 23.6.0: Mon Jul 29 21:14:04 PDT 2024; root:xnu-10063.141.2~1/RELEASE_ARM64_T8122
Then start lldb from Terminal, using this command:
bash_prompt % lldb -arch arm64e /Library/Developer/KDKs/KDK_14.6.1_23G93.kdk/System/Library/Kernels/kernel.release.t8122
Next I load the remaining scripts per the instructions from lldb:
(lldb) settings set target.load-script-from-symbol-file true
I need to know what address to load my kext symbols to, which I read from this line of the panic log, after the @ symbol:
com.company.product(1.4.21d119)[92BABD94-80A4-3F6D-857A-3240E4DA8009]@0xfffffe001203bfd0->0xfffffe00120533ab
I am using a debug build of my kext, so the DWARF symbols are part of the binary. I use this line to load the symbols into the lldb session:
(lldb) addkext -F /Library/Extensions/KextName.kext/Contents/MacOS/KextName 0xfffffe001203bfd0
And now I should be able to use lldb image lookup to identify pointers on the stack that land within my kext. For example, the current PC at the moment of the crash lands within the kext (expected, because it was intentional):
(lldb) image lookup -a 0xfffffe001203fe10
Which gives the following incorrect result:
Address: KextName[0x0000000000003e40] (KextName.__TEXT.__cstring + 14456)
Summary: "ffer has %d retains\n"
That's not even a program instruction - that's within a cstring. No, that cstring isn't involved in anything pertaining to the intentional panic I am expecting to see.
Can someone please explain what I'm doing wrong and provide instructions that will give symbol information from a panic trace on an Apple Silicon Mac?
Disclaimers:
Yes I know IOPCIFamily is deprecated, I am in process of transitioning to DriverKit Dext from IOKit kext. Until then I must maintain the kext.
Terminal command "atos" provides similar incorrect results, and seems to not work with debug-built-binaries (only dSYM files)
Yes this is an intentional panic so that I can verify the symbolicate process before I move on to investigating an unexpected panic
I have set nvram boot-args to include keepsyms=1
I have tried (lldb) command script import lldb.macosx but get a result of error: no images in crash log (after the nvram settings)
I want to get MacOS Version from Objective-C build for iOS Apps to run on Apple Silicon Mac.
Because AppStore In-App Purchase on Apple Silicon Mac had issues on MacOS version 13.0 and was fixed at version 13.3.1.
I need to know the exact version of the MacOS to prevent users from buying In-App Purchases.
I found that I can get iOS version that the app is emulating on and assume
MacOS version from iOS version. But I think it's not 100% guaranteed way, because no documentation says anything about it.
Is there a way to get MacOS Version in iOS Apps running on Apple Silicon Mac?
Helpppp.
I installed Krita from the Appstore, it works. Then install ai_diffusion and I got :
xcrun: error: cannot be used within an App Sandbox.
Can anybody help me?
Thanks.
AttributeError
Python 3.10.7: /Applications/krita.app/Contents/MacOS/krita
Sat Aug 3 18:15:59 2024
A problem occurred in a Python script. Here is the sequence of
function calls leading up to the error, in the order they occurred.
/Users/alejandropereira/Library/Containers/org.kde.krita/Data/Library/Application Support/krita/pykrita/ai_diffusion/ui/region.py in update_settings(self=<ai_diffusion.ui.region.ActiveRegionWidget object>, key='prompt_translation', value=None)
345 self._layout_language_button()
346 elif key == "prompt_translation":
347 self._update_language()
348
349 async def _replace_with_translation(self, client: Client):
self = <ai_diffusion.ui.region.ActiveRegionWidget object>
self._update_language = >
/Users/alejandropereira/Library/Containers/org.kde.krita/Data/Library/Application Support/krita/pykrita/ai_diffusion/ui/region.py in _update_language(self=<ai_diffusion.ui.region.ActiveRegionWidget object>)
381 enabled = self._root._model.translation_enabled
382 lang = settings.prompt_translation if enabled else "en"
383 self._language_button.setText(lang.upper())
384 if enabled:
385 text = self._lang_help_enabled
self = <ai_diffusion.ui.region.ActiveRegionWidget object>
self._language_button = <PyQt5.QtWidgets.QToolButton object>
self._language_button.setText =
lang = None
lang.upper undefined
AttributeError: 'NoneType' object has no attribute 'upper'
cause = None
class = <class 'AttributeError'>
context = None
delattr = <method-wrapper 'delattr' of AttributeError object>
dict = {}
dir =
doc = 'Attribute not found.'
eq = <method-wrapper 'eq' of AttributeError object>
format =
ge = <method-wrapper 'ge' of AttributeError object>
getattribute = <method-wrapper 'getattribute' of AttributeError object>
gt = <method-wrapper 'gt' of AttributeError object>
hash = <method-wrapper 'hash' of AttributeError object>
init = <method-wrapper 'init' of AttributeError object>
init_subclass =
le = <method-wrapper 'le' of AttributeError object>
lt = <method-wrapper 'lt' of AttributeError object>
ne = <method-wrapper 'ne' of AttributeError object>
new =
reduce =
reduce_ex =
repr = <method-wrapper 'repr' of AttributeError object>
setattr = <method-wrapper 'setattr' of AttributeError object>
setstate =
sizeof =
str = <method-wrapper 'str' of AttributeError object>
subclasshook =
suppress_context = False
traceback =
args = ("'NoneType' object has no attribute 'upper'",)
name = 'upper'
obj = None
with_traceback =
The above is a description of an error in a Python program. Here is
the original traceback:
Traceback (most recent call last):
File "/Users/alejandropereira/Library/Containers/org.kde.krita/Data/Library/Application Support/krita/pykrita/ai_diffusion/ui/region.py", line 347, in update_settings
self._update_language()
File "/Users/alejandropereira/Library/Containers/org.kde.krita/Data/Library/Application Support/krita/pykrita/ai_diffusion/ui/region.py", line 383, in _update_language
self._language_button.setText(lang.upper())
AttributeError: 'NoneType' object has no attribute 'upper'
Hello,
I have an iPad app that users are running on their M1 / M2 MacBooks thanks to the "Designed for iPad" feature.
Some of them reported to me that the pressed keyboard keys were not recognized.
According to my source code, it seems that my custom views (that are set as firstResponder) do not get pressesBegan events.
While I could not reproduce this specific problem on my M1 Macbook, I found a strange problem that may be related.
My view also supports interaction with game controllers.
I found that the emulated controller (which is using the keyboard, when the controller emulation feature of the Designed for iPad app is set to On) has some problems.
The valueChangedHandler of the GCExtendedGamepad from the GCGameController is only fired if the app is compiled with the "Requires full screen" option set to On.
If Requires full screen is unchecked in XCode, the Emulated Controller is still present in the list of game controllers, but no button callbacks are triggered.
Note that a real game controller connected via USB will work correctly no matter how Requires full screen is set.
Could there be a focus bug of the keyboard not sending events when the app is not a full screen app (resizable on mac, and multitask on iPad)?
Or is there something I can change to avoid this problem?
I'm lost.
Our apps can currently be installed on Apple Silicon Macs via the iPad app on Mac feature (“Designed for iPad”). Now we are working on “proper” (universal) Catalyst-based Mac apps that will be available on the Mac App Store.
How does the transition work for users that currently have the iPad version installed? Will they automatically update to the Mac Catalyst app once it’s available, or do they need to re-install the app from the Mac App Store?
Hello all,
I am wondering if anyone can help me with writing a script that fully uninstalls an app with one click or can point me to a script already written please? So that when I click the script it uninstalls the app and leaves nothing behind. So when I click finder and use the search function with the name of the app, then click add and then name matches (input name of app) then click add and select system files are included, nothing comes up as the script has completely removed it from my system.
I am Using Mac Mini M2 Pro 16gb ram and macOS Sonoma.
Thank you
Hi,
Reading the
copyFromBuffer
documentation states that on macOS, sourceOffset, destinationOffset, and size "needs to be a multiple of 4, but can be any value in iOS and tvOS".
However, I have noticed that, at least on my M2 Max, this limitation does not seem to exist as there are no warnings and the copy works correctly regardless of the offset value.
I'm curious to know if this is something that should still be avoided. Is the multiple of 4 limitation reserved for non Apple Silicon devices and that note can be ignored for Apple Silicon?
I ask because I am a contributor to Metal.jl, and recently noticed that our tests pass even when copying using copyWithBuffer with offsets and sizes that are not multiples of 4. If that coul cause issues/correctness problems, we would need to fix that.
Thank you.
Christian
I use to testing iOS app directly on my M1 Mac mini, without needing to plug in an iPhone. After updated to XCode 15.4, this option is gone.
Recently I started getting emails from AppStoreConnect when I submit new builds The email states:
ITMS-90863: Macs with Apple silicon support issue - The app links with libraries that aren’t present in macOS: /usr/lib/swift/libswiftCloudKit.dylib
I can run this app on apple silicon from TestFlight or directly from Xcode and it runs just fine including all iCloud functions. This app has been using iCloud for several years now.
So my question is: Should I just ignore the email or do I need to change something to bring this app into compliance?
Hi All,
Finder is caching the old application name and not showing the new application.
I am deploying my iPad app to M1 Mac by generating a package file. In the newer version of this application, I have changed my application name and deployed the application from backend to user machines.
Eventhough application is deployed successfully, the application name still remains the old. I went through the forum and tried the reset the finder cache and launcher service caches, but still the new application name is not coming.
But when I uninstall and reinstall the application it is showing the new application name.
Can someone suggest a way to reset this using script, as we are deploying the application from backend, we dont have direct access to the client machines
Thanks
Ranga
When rendering gradient of luma values you can clearly see that the monitor output from Apple Silicon GPU has lifted/curved blacks (values 0-31 out of 1024 in 10-bit output).
Any idea what is going on and how to remediate? It looks like some kind of compensation/calibration for the screen panel response, but it is baked into output regardless of what kind of monitor (or non-monitor) is connected.
The same rendering on Intel architecture produces correct linear gradation. We have tried M1, M2, M3 and they all seem to be affected.