Oh right since we're in this thread. Well,
Part 1 Input Redirecting to your controller
1. Connect your controller to your android phone in whatever way works (usb or bluetooth).
2. Install and start IRdA on your phone.
3. Map your controller to the 3ds inputs. Press the buttons on your controller and choose what respective button on your 3ds you want it to be mapped to. Ex if you press A on your controller then you can choose A from the list. The trick is to map your controller to buttons you won't be using on your 3ds since you'll have to divide all buttons available on your 3ds between the 3ds and the second controller. Here's some tips: map the controller A as R on the 3ds. B as L. L2 as Y and R2 as X. You can also map one of those controller buttons as Select on the 3DS. You'll get how this works when you try it. For your analog sticks you have to press "CAL axis" and choose the axis you want and press OK on the options you get. Cpad is left stick. Cstick is right stick.
4. Start input redirection on your 3ds. Enter Rosalina menu on your 3ds (l+dpad down+select). Go to miscellaneous options. Press "Start InputRedirection".
5. Press B and take note of the IP adress on the top right of your screen.
6. Press input IP address in the options in IRdA and write that IP address. *Obviously your phone and 3DS has to be connected to the same network. Your 3ds can be connected to your android's hotspot also.
7. Exit out of rosalina and you should be able to control your 3ds with the controller.
Part 2 Retroarch Multiplayer
1. Go to settings and input. Scroll down to User 2 and set device to 3ds. Use the latest stable retroarch.
2. Start any game with the emulator you want (snes9x2002 has issues with input changing.).
3. Go to quickmenu and controls. Go to Player 2 and set the corresponding left analog axes as dpad directions. Now, remember how you mapped your controller earlier and scroll down and set L as A and R as B etc. Then set Left Analog as the dpad by mapping the respective direction. The person using the controller will have to use the analog stick for movement, because the 3ds' circlepad won't work on the 3ds as long as it is receiving input from a controller for some reason.
4. Make sure two controllers are connected for the system you're emulating. Sometimes this is in quickmenu options (i.e. pcsx_rearmed) other times in controls.
5. You should be ready to play.