Also I think in case of liquidation mortgage creditors take preference over debentures. Debentures can be converted to shares but mortgage cannot
A deed creating a charge over securities (including shares) which are in registered form, title to which is recorded in a register and represented by a certificate.
The deed creates a first fixed charge over existing and future registered securities in certificated form, and over interests accruing from those securities.
In my experience debentures are converted to shares when it appears that the loan is unlikely to be repaid and the company can be viable when the burden of repayment has been lifted. Having shares also means the former debenture holder has some influence over the running of the comany.
It could be a bond and floating charge. That will be secured over the assets of the company but will only crystalise when the company goes into liquidation.
If the loan was converted to shares there will be an increase in the share capital on the balance sheet coupled with a reduction in liabilities.
A company can only buy its own shares if there is distributable profits.