Creating a C-ABI compatible function signature with a struct

Is there some way to create a target-specific C-ABI compatible function
signature using LLVM?

For example, this C-Code:

typedef struct vpt\_data \{
    char x;
    int a;
    char c;
    float b;
\} vpt\_data;

void vpt\_test\( vpt\_data vd \) \{

Generates a function:

define void @vpt\_test\(i64 %vd\.coerce0, i64 %vd\.coerce1\) \#0 \{

And also packs/unpacks the structure values when calling/being called.

If I create the function signature `vpt_test( vpt_data vd)` in LLVM
however, it will just pass the structure as is to the function (push on
stack I presume). This means I can't call any C functions that accept

I've seen some old threads indicating this was the job of the frontend,
but perhaps a function in LLVM has been created since then. It also
feels like this is something that LLVM should be doing, otherwise I'd
need to create my own code to do this structuring for each target
machine I want to support.