Modular

M

Modular

This server is the home of the MAX and Mojo community. Join us to chat about all things Modular!

Join

questions

community-showcase

Determine Pointer Location

Hey everyone :) Got stuck on an issue and was wondering if anyone knew how to implement a kind of function to check if a pointer is allocated on the stack or the heap, i.e. ```rust...

What github actions are folks using for CI?

I imagine an official mojo package workflow will emerge once packaging is reasonably settled. In the meantime, how do you all run tests, generate docs, etc. with github actions?

UnsafePointer & Structs

would anyone be able to help me understand what is happening here? why are the outputs of the two print statements different? ``` @value struct Test: ...

Fixed Point

Does mojo float point support fixed point to be sure cross platform have all the same float number?

crypto lib

is there a crypto library for mojo with an implementation of AES

MAX on Arch Linux?

I just wanted to know an official Arch Linux package was anywhere on the horizon. Seems like a no-brainer to add official support for the Arch family of distros. I am excited by the promise of Mojo and MAX, and I would like to explore it further, but I'll die before I install Debian again.
No description

Does Mojo have inline assembly?

Does Mojo currently have a blessed way to do inline assembly? LLVM doesn't have intrinsics for ARM MSR reads, and the two best clocks on an ARM system from a microbenchmark perspective are cntvct_el0 and pmccntr_el0, both of which are MSRs. In C I would normally read them as follows: ```c uint64_t tsc; ...

Would you be interested in BigInt support?

I did some programming exercises in Mojo and noticed that BigInt support is missing, and Mojo should probably support BigInt at some point, seeing as Python uses arbitrary precision integers by default. Are there any other users missing this? Would it make sense for me to start working on this as a Mojo stdlib PR or is this the sort of thing Mojo would rather have as a 3rd party library for now?...

I do not know why the output is like this!

I ran two almost identical programmes but the output changed. But I don't understand why the output changes. I would like to know. First Program ```def greet(name: String):...

mojo windows

When will mojo for windows be released

Iterating over unknown sizes

Mojo iterators use the size and not an exception to indicate the end of an iterator. Is it still somehow possible to iterate over collections that don't have an upfront known size (like streams of data) ?...

Mojo nightly auth

Hi! Why does installing nightly/mojo requires authentication while installing the stable does not? I would like to have a nightly mojo container but it complicates the build.

Any Plans for SPIR-V/OpenCL Support?

Are there any plans for a SPIR-V target for Mojo or an OpenCL backend for Max? It would be useful since it would allow leveraging OpenCL compatible hardware instead of whatever Modular can specifically add support for, in particular FPGAs are very good at inference on small models on price/perf when looking at major cloud providers.

Regular packages for Linux and installation without login

It's almost impossible to log in and install mojo in China and Slavic countries without perfectly configurated proxy. It's OK if you would need to login to install and use a proprietary stuff but why we need log in to use Open Source project? Mojo would be much more popular if it was distributed like a normal package without login

How to get a string out of an __mlir_type.i256 ?

Using the llvm dialect, I can add numbers of any size, In this picture I add 256 bit numbers. This compiled and ran, which is wonderful, but now I don't know how to get a string out of var c so I can see the result. In stdlib, the way to print a scalar is so convoluted and complex that I was not able to understand it. If someone knows how to do it using simple MLIR operations, it could benefit anyone trying to create a custom mojo type using MLIR. ...
No description

Traits with compile-time SIMD size

I can't seem to fulfill a trait that can return different length SIMDs ```mojo trait PRNGEngine(Movable): @staticmethod fn ndim() -> Int:...

Specialize on trait

As far as I can tell, the following will not compile: ``` trait T1: pass ...

software cost estimating

That article does not understand software economics. COCOMO is used as a very rough estimate for early development, when most of the work is cookie-cutter code. It is also generally disputed and not viewed as accurate for projecting real effort. For that matter, LOC is not a particularly good metric for assessing a code base: not for assessing concepts of "maintainability" or "cost" or "defect rate" or any other metric of code health. It is often used as a base starting point (i.e., given everything else being identical, a code base 2x as large will cost roughly 2x as much), but all the other factors are often considered more important. "All the other factors" include things like modularity, code complexity (many methods of measurement), token count (similar to line count, but not just measuring lines; i.e., some lines have a LOT of tokens, while other lines have only one token), and more. I used to work for a company that had many patents around concepts of code complexity. We were one of many companies with a "cost estimator" tool, too. And we all knew (and openly admitted) that our estimator (just like all others) was very, very, very rough. I.e., cost could easily be 50% of our estimate or 2x our estimate -- the statistical deviation was wide. Our statistical relevance was so-so at best. Same with other models. Finance people still loved the models because you have to assess cost projections somehow, even when you know the estimates are widely flawed. Side note: this is one of the many "holy grail" targets. If you can make an accurate (good luck) cost projection tool to help organizations identify "cost to complete a software project," then you have a product you can sell for $$. Just don't step into the ring assuming that nobody has tried. There are literally dozens of companies shilling various models, and they all sorta suck. Very wide margins-of-error (statistical deviations). As of a couple years ago, there was not a product in existence that is substantially more accurate than quality engineering managers giving a "guestimate" based on decades of experience. Some companies sell massive reports that combine all of the current estimation methods (we sold our estimates to a couple prominent report-generation companies, like Black Duck), but there is no single "this number is pretty good" solution. At least not as of ~2 years ago; last time I was working in that field....

Mojo SDK API-KEY?

Where do I generate the API-KEY required by the MOJO-SDK (account at developer.modular.com seams not to provide key generation)?